summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGlenn Kasten <gkasten@google.com>2015-06-04 13:28:50 -0700
committerGlenn Kasten <gkasten@google.com>2015-06-04 15:30:55 -0700
commit0d4d82daff89115d5a6318c53f94f22fa36a862b (patch)
tree106ed26871fd211febb2ae125a91f5fb6c3068ac
parent274c079467f6ade516771b4c721c67041243cf4b (diff)
downloadandroid_frameworks_wilhelm-0d4d82daff89115d5a6318c53f94f22fa36a862b.tar.gz
android_frameworks_wilhelm-0d4d82daff89115d5a6318c53f94f22fa36a862b.tar.bz2
android_frameworks_wilhelm-0d4d82daff89115d5a6318c53f94f22fa36a862b.zip
Compare raw pointers to NULL
Change-Id: I2ab197f2f20ff22204e01d0e115f2aee2f5ef166
-rw-r--r--src/data.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/data.c b/src/data.c
index 9f360e1..cbb2c49 100644
--- a/src/data.c
+++ b/src/data.c
@@ -425,20 +425,20 @@ static SLresult checkDataFormat(const char *name, void *pFormat, DataFormat *pDa
// check the container bit depth
switch (pDataFormat->mPCM.containerSize) {
case 8:
- if (df_representation &&
+ if (df_representation != NULL &&
*df_representation != SL_ANDROID_PCM_REPRESENTATION_UNSIGNED_INT) {
result = SL_RESULT_PARAMETER_INVALID;
}
break;
case 16:
case 24:
- if (df_representation &&
+ if (df_representation != NULL &&
*df_representation != SL_ANDROID_PCM_REPRESENTATION_SIGNED_INT) {
result = SL_RESULT_PARAMETER_INVALID;
}
break;
case 32:
- if (df_representation
+ if (df_representation != NULL
&& *df_representation != SL_ANDROID_PCM_REPRESENTATION_SIGNED_INT
&& *df_representation != SL_ANDROID_PCM_REPRESENTATION_FLOAT) {
result = SL_RESULT_PARAMETER_INVALID;