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

Commit 120b7fa3 authored by Chih-Hung Hsieh's avatar Chih-Hung Hsieh Committed by Android Git Automerger
Browse files

am 62ea6b26: am ce1928e9: Merge "Add required casts for clang/llvm -Wc++11-narrowing"

* commit '62ea6b26':
  Add required casts for clang/llvm -Wc++11-narrowing
parents 1f7aabf6 62ea6b26
Loading
Loading
Loading
Loading
+2 −2
Original line number Original line Diff line number Diff line
@@ -131,8 +131,8 @@ inline status_t Mutex::tryLock() {
#if HAVE_ANDROID_OS
#if HAVE_ANDROID_OS
inline status_t Mutex::timedLock(nsecs_t timeoutNs) {
inline status_t Mutex::timedLock(nsecs_t timeoutNs) {
    const struct timespec ts = {
    const struct timespec ts = {
        /* .tv_sec = */ timeoutNs / 1000000000,
        /* .tv_sec = */ static_cast<time_t>(timeoutNs / 1000000000),
        /* .tv_nsec = */ timeoutNs % 1000000000,
        /* .tv_nsec = */ static_cast<long>(timeoutNs % 1000000000),
    };
    };
    return -pthread_mutex_timedlock(&mMutex, &ts);
    return -pthread_mutex_timedlock(&mMutex, &ts);
}
}