Cast sleep to int

Change-Id: Icb4e9454e0f8c033507c9312a334e7153d1974af