summaryrefslogtreecommitdiff
path: root/src/time/timer_settime.c
diff options
context:
space:
mode:
authorRich Felker <dalias@aerifal.cx>2014-01-06 22:05:54 -0500
committerRich Felker <dalias@aerifal.cx>2014-01-06 22:05:54 -0500
commiteca335fc0453d3680fd9f112574919e13fab31d2 (patch)
tree4cb5225adcd4508405087557f74da1096be3b7d5 /src/time/timer_settime.c
parent839cc4e6da609a0b24f6cc32b0b11558fd77dd83 (diff)
downloadmusl-eca335fc0453d3680fd9f112574919e13fab31d2.tar.gz
eliminate explicit (long) casts when making syscalls
this practice came from very early, before internal/syscall.h defined macros that could accept pointer arguments directly and handle them correctly. aside from being ugly and unnecessary, it looks like it will be problematic when we add support for 32-bit ABIs on archs where registers (and syscall arguments) are 64-bit, e.g. x32 and mips n32.
Diffstat (limited to 'src/time/timer_settime.c')
-rw-r--r--src/time/timer_settime.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/time/timer_settime.c b/src/time/timer_settime.c
index f5f36feb..62631aa4 100644
--- a/src/time/timer_settime.c
+++ b/src/time/timer_settime.c
@@ -8,5 +8,5 @@ int timer_settime(timer_t t, int flags, const struct itimerspec *restrict val, s
pthread_t td = (void *)((uintptr_t)t << 1);
t = (void *)(uintptr_t)(td->timer_id & INT_MAX);
}
- return syscall(SYS_timer_settime, (long)t, flags, val, old);
+ return syscall(SYS_timer_settime, t, flags, val, old);
}