diff options
author | Elliott Hughes <enh@google.com> | 2017-06-12 19:56:56 +0000 |
---|---|---|
committer | android-build-merger <android-build-merger@google.com> | 2017-06-12 19:56:56 +0000 |
commit | 184fa60c23e8b6092903529934c86267e3a1df8c (patch) | |
tree | f708ee35a565e63472e3f072dd173d711df0f4e5 /libcutils | |
parent | 3b0512b75c465a7727738cc58216a828a5500b4a (diff) | |
parent | 316b7334b89215fc813182ab654a1c880ab9b21d (diff) | |
download | core-184fa60c23e8b6092903529934c86267e3a1df8c.tar.gz core-184fa60c23e8b6092903529934c86267e3a1df8c.tar.bz2 core-184fa60c23e8b6092903529934c86267e3a1df8c.zip |
Merge "Fix prctl argument type" am: 6cc5927e0d
am: 316b7334b8
Change-Id: Iaaf987d8b996a44a0b11eae3a1f1386adf721f3c
Diffstat (limited to 'libcutils')
-rw-r--r-- | libcutils/sched_policy.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libcutils/sched_policy.cpp b/libcutils/sched_policy.cpp index e29a8444c..7e385355f 100644 --- a/libcutils/sched_policy.cpp +++ b/libcutils/sched_policy.cpp @@ -340,7 +340,7 @@ int set_cpuset_policy(int tid, SchedPolicy policy) return 0; } -static void set_timerslack_ns(int tid, unsigned long long slack) { +static void set_timerslack_ns(int tid, unsigned long slack) { // v4.6+ kernels support the /proc/<tid>/timerslack_ns interface. // TODO: once we've backported this, log if the open(2) fails. if (__sys_supports_timerslack) { @@ -348,7 +348,7 @@ static void set_timerslack_ns(int tid, unsigned long long slack) { snprintf(buf, sizeof(buf), "/proc/%d/timerslack_ns", tid); int fd = open(buf, O_WRONLY | O_CLOEXEC); if (fd != -1) { - int len = snprintf(buf, sizeof(buf), "%llu", slack); + int len = snprintf(buf, sizeof(buf), "%lu", slack); if (write(fd, buf, len) != len) { SLOGE("set_timerslack_ns write failed: %s\n", strerror(errno)); } |