Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b4213f75 authored by Okan Arikan's avatar Okan Arikan
Browse files

Nullptr check for VSyncClient::Wait

as the documentation in the header implies

Bug: 34609900
Test: pass nullptr to Wait and observe your code not crashing
Change-Id: Ia3ead8cf3369bddedfca4606d0fa261fd57c281f
(cherry picked from commit a919630f3c7cd3c2ee90ef39cbf8147681dd9be8)
parent 2c275922
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -26,7 +26,10 @@ int VSyncClient::Wait(int64_t* timestamp_ns) {
          status.GetErrorMessage().c_str());
    return -status.error();
  }

  if (timestamp_ns != nullptr) {
    *timestamp_ns = status.get();
  }
  return 0;
}