From ffb88b0da4df3d6a2db80670a176397db5ff6515 Mon Sep 17 00:00:00 2001 From: Vladimir Chtchetkine Date: Fri, 23 Sep 2011 13:38:12 -0700 Subject: CherryPick from 3d3fea0 in master. Do not merge. Fix windows build Change-Id: I6b82dd84860a5b634fb5215a0ef250e9e13bc2a2 --- android/camera/camera-common.h | 2 +- android/camera/camera-service.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/android/camera/camera-common.h b/android/camera/camera-common.h index 37bdef4..de09045 100755 --- a/android/camera/camera-common.h +++ b/android/camera/camera-common.h @@ -189,7 +189,7 @@ _get_timestamp(void) /* Sleeps for the given amount of milliseconds */ static __inline__ void -_sleep(int millisec) +_camera_sleep(int millisec) { struct timeval t; const uint64_t wake_at = _get_timestamp() + (uint64_t)millisec * 1000; diff --git a/android/camera/camera-service.c b/android/camera/camera-service.c index e40035f..ee3ea6e 100644 --- a/android/camera/camera-service.c +++ b/android/camera/camera-service.c @@ -1247,7 +1247,7 @@ _camera_client_query_frame(CameraClient* cc, QemudClient* qc, const char* param) while (repeat == 1 && !cc->frames_cached && (_get_timestamp() - tick) < 2000000LL) { /* Sleep for 10 millisec before repeating the attempt. */ - _sleep(10); + _camera_sleep(10); repeat = camera_device_read_frame(cc->camera, fbs, fbs_num); } if (repeat == 1 && !cc->frames_cached) { -- cgit v1.1