diff options
| author | 2014-05-08 14:56:50 -0700 | |
|---|---|---|
| committer | 2014-05-08 14:56:50 -0700 | |
| commit | 150ecd8c1bd5543bf0a65ac838a7409131106716 (patch) | |
| tree | 552410ae2c03ee5ebf18d37e675c8d507f25ec68 | |
| parent | 98e1ebc026726ba045cea69b1b8c371d95db9893 (diff) | |
Add mutex
Change-Id: I81072031e74a5cca8384e4e8bce4babf2187d8bb
| -rw-r--r-- | services/surfaceflinger/DispSync.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/services/surfaceflinger/DispSync.cpp b/services/surfaceflinger/DispSync.cpp index fd4682225b..2ee7570365 100644 --- a/services/surfaceflinger/DispSync.cpp +++ b/services/surfaceflinger/DispSync.cpp @@ -509,6 +509,7 @@ void DispSync::resetErrorLocked() { } nsecs_t DispSync::computeNextRefresh(int periodOffset) const { + Mutex::Autolock lock(mMutex); nsecs_t now = systemTime(SYSTEM_TIME_MONOTONIC); return (((now - mPhase) / mPeriod) + periodOffset + 1) * mPeriod + mPhase; } |