diff options
author | Jason Sams <rjsams@android.com> | 2011-03-18 17:08:54 -0700 |
---|---|---|
committer | Jason Sams <rjsams@android.com> | 2011-03-18 17:08:54 -0700 |
commit | 80e29cf5c45e378bd28a1b061bb70d8ce02846ae (patch) | |
tree | 2acad3f462f0cbd70197607f7382b7f506ab316a /libs/rs/driver/rsdCore.cpp | |
parent | 233c43c331e090ab8c15daccd5dcb9ce577996fb (diff) | |
download | frameworks_base-80e29cf5c45e378bd28a1b061bb70d8ce02846ae.zip frameworks_base-80e29cf5c45e378bd28a1b061bb70d8ce02846ae.tar.gz frameworks_base-80e29cf5c45e378bd28a1b061bb70d8ce02846ae.tar.bz2 |
Fix bug with hal init uninitialized var.
Change-Id: I172bb65b57653e32697f2c2df941beb0aaf65603
Diffstat (limited to 'libs/rs/driver/rsdCore.cpp')
-rw-r--r-- | libs/rs/driver/rsdCore.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libs/rs/driver/rsdCore.cpp b/libs/rs/driver/rsdCore.cpp index bb6cce9..6546110 100644 --- a/libs/rs/driver/rsdCore.cpp +++ b/libs/rs/driver/rsdCore.cpp @@ -111,7 +111,8 @@ bool rsdHalInit(Context *rsc, uint32_t version_major, uint32_t version_minor) { rsc->mHal.funcs = FunctionTable; RsHal *dc = (RsHal *)calloc(1, sizeof(RsHal)); - if (!rsc->mHal.drv) { + if (!dc) { + LOGE("Calloc for driver hal failed."); return false; } rsc->mHal.drv = dc; |