diff options
| author | Tim Murray <timmurray@google.com> | 2014-04-17 23:47:23 +0000 |
|---|---|---|
| committer | Android Git Automerger <android-git-automerger@android.com> | 2014-04-17 23:47:23 +0000 |
| commit | c314d0758a3713eda514a200a3879843bbaef69e (patch) | |
| tree | dfb3c51f9a70b00dff2d53b486c784a4b66e438e /rsContext.cpp | |
| parent | b9b11a105f7c6bf90bd28a5df9b445cab9cbdfce (diff) | |
| parent | 05469137d372647e1de914eb0d68fa38c2c2a6ee (diff) | |
| download | android_frameworks_rs-c314d0758a3713eda514a200a3879843bbaef69e.tar.gz android_frameworks_rs-c314d0758a3713eda514a200a3879843bbaef69e.tar.bz2 android_frameworks_rs-c314d0758a3713eda514a200a3879843bbaef69e.zip | |
am 05469137: am b429ee59: Merge "Add error check when init RS thread in sync mode."
* commit '05469137d372647e1de914eb0d68fa38c2c2a6ee':
Add error check when init RS thread in sync mode.
Diffstat (limited to 'rsContext.cpp')
| -rw-r--r-- | rsContext.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/rsContext.cpp b/rsContext.cpp index 705ede41..4c5e85a1 100644 --- a/rsContext.cpp +++ b/rsContext.cpp @@ -579,6 +579,11 @@ bool Context::initContext(Device *dev, const RsSurfaceConfig *sc) { timerSet(RS_TIMER_INTERNAL); if (mSynchronous) { threadProc(this); + + if (mError != RS_ERROR_NONE) { + ALOGE("Errors during thread init (sync mode)"); + return false; + } } else { status = pthread_create(&mThreadId, &threadAttr, threadProc, this); if (status) { @@ -612,7 +617,7 @@ Context::~Context() { } rsAssert(mExit); - if (mHal.funcs.shutdownDriver) { + if (mHal.funcs.shutdownDriver && mHal.drv) { mHal.funcs.shutdownDriver(this); } |
