diff options
| author | Glenn Kasten <gkasten@google.com> | 2012-11-12 07:44:56 -0800 |
|---|---|---|
| committer | Glenn Kasten <gkasten@google.com> | 2013-08-02 10:54:34 -0700 |
| commit | 3eaa329775fc522d8ea4acd4edc379eabf9ac332 (patch) | |
| tree | 30796edd85c16a70beeb3dbff2a69cb101482999 /src | |
| parent | 03a012a855b7edcda0b799031d70765769057be5 (diff) | |
| download | android_frameworks_wilhelm-3eaa329775fc522d8ea4acd4edc379eabf9ac332.tar.gz android_frameworks_wilhelm-3eaa329775fc522d8ea4acd4edc379eabf9ac332.tar.bz2 android_frameworks_wilhelm-3eaa329775fc522d8ea4acd4edc379eabf9ac332.zip | |
Fix build warnings
narrowing conversion of '-1' from 'int' to 'SLuint32 {aka unsigned int}' inside { } is ill-formed in C++11 [-Wnarrowing]
converting to non-pointer type 'pthread_t {aka long int}' from NULL [-Wconversion-null]
warning: 'currentRate' may be used uninitialized in this function [-Wmaybe-uninitialized]
Change-Id: I066260cc216ff9f15c787f65e3d3efbda8f8ef35
Diffstat (limited to 'src')
| -rw-r--r-- | src/android/CallbackProtector.cpp | 6 | ||||
| -rw-r--r-- | src/devices.c | 4 |
2 files changed, 5 insertions, 5 deletions
diff --git a/src/android/CallbackProtector.cpp b/src/android/CallbackProtector.cpp index 85eceac..7b9f107 100644 --- a/src/android/CallbackProtector.cpp +++ b/src/android/CallbackProtector.cpp @@ -27,9 +27,9 @@ CallbackProtector::CallbackProtector() : RefBase(), mSafeToEnterCb(true), mCbCount(0) #ifdef USE_DEBUG - , mCallbackThread(NULL), + , mCallbackThread((pthread_t) NULL), mCallbackTid(0), - mRequesterThread(NULL), + mRequesterThread((pthread_t) NULL), mRequesterTid(0) #endif { @@ -101,7 +101,7 @@ void CallbackProtector::exitCb() { mCbExitedCondition.broadcast(); } #ifdef USE_DEBUG - mCallbackThread = NULL; + mCallbackThread = (pthread_t) NULL; mCallbackTid = 0; #endif } diff --git a/src/devices.c b/src/devices.c index 920dd5e..9959360 100644 --- a/src/devices.c +++ b/src/devices.c @@ -89,7 +89,7 @@ const struct AudioOutput_id_descriptor AudioOutput_id_descriptors[] = { static const SLLEDDescriptor SLLEDDescriptor_default = { 32, // ledCount 0, // primaryLED - ~0 // colorMask + (SLuint32) ~0 // colorMask }; const struct LED_id_descriptor LED_id_descriptors[] = { @@ -169,7 +169,7 @@ static const SLAudioCodecDescriptor CodecDescriptor_A = { sizeof(SamplingRates_A) / sizeof(SamplingRates_A[0]), // numSampleRatesSupported 1, // minBitRate - ~0, // maxBitRate + (SLuint32) ~0, // maxBitRate SL_BOOLEAN_TRUE, // isBitrateRangeContinuous NULL, // pBitratesSupported 0, // numBitratesSupported |
