am 46578a4a: Fix NanoSleep and add test

* commit '46578a4a3bf235fde35ed80c6e6cbe8fb5f06b48':
  Fix NanoSleep and add test