diff options
-rw-r--r-- | linux-user/syscall.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/linux-user/syscall.c b/linux-user/syscall.c index ab9d933e53..ce399a55f0 100644 --- a/linux-user/syscall.c +++ b/linux-user/syscall.c @@ -2632,6 +2632,7 @@ static abi_long do_getsockopt(int sockfd, int level, int optname, default: goto unimplemented; } + break; #endif /* SOL_NETLINK */ default: unimplemented: @@ -7763,10 +7764,12 @@ static abi_long do_syscall1(void *cpu_env, int num, abi_long arg1, #ifdef TARGET_NR_stime /* not on alpha */ case TARGET_NR_stime: { - time_t host_time; - if (get_user_sal(host_time, arg1)) + struct timespec ts; + ts.tv_nsec = 0; + if (get_user_sal(ts.tv_sec, arg1)) { return -TARGET_EFAULT; - return get_errno(stime(&host_time)); + } + return get_errno(clock_settime(CLOCK_REALTIME, &ts)); } #endif #ifdef TARGET_NR_alarm /* not on alpha */ |