Enhanced error reporting for usleep.