summaryrefslogtreecommitdiffstats
path: root/linux-user/qemu.h
diff options
context:
space:
mode:
authorFilip Bozuta2020-07-27 22:13:26 +0200
committerLaurent Vivier2020-08-27 12:29:49 +0200
commitb09d64064bd1ea5e5c37b2d5089e1cc3f65801b2 (patch)
tree4a5ac55a94cdbe0ac5afe1fa455d98445ef2d861 /linux-user/qemu.h
parentlinux-user: Fix 'semop()' and 'semtimedop()' implementation (diff)
downloadqemu-b09d64064bd1ea5e5c37b2d5089e1cc3f65801b2.tar.gz
qemu-b09d64064bd1ea5e5c37b2d5089e1cc3f65801b2.tar.xz
qemu-b09d64064bd1ea5e5c37b2d5089e1cc3f65801b2.zip
linux-user: Fix 'clock_nanosleep()' implementation
Implementation of syscall 'clock_nanosleep()' in 'syscall.c' uses functions 'target_to_host_timespec()' and 'host_to_target_timespec()' to transfer the value of 'struct timespec' between target and host. However, the implementation doesn't check whether this conversion succeeds and thus can return an unaproppriate error instead of 'EFAULT' that is expected. This was confirmed with the modified LTP test suite where testcases with bad 'struct timespec' adress for 'clock_nanosleep()' were added. This modified LTP suite can be found at: https://github.com/bozutaf/ltp (Patch with this new test case will be sent to LTP mailing list soon) Signed-off-by: Filip Bozuta <Filip.Bozuta@syrmia.com> Reviewed-by: Laurent Vivier <laurent@vivier.eu> Message-Id: <20200727201326.401519-1-Filip.Bozuta@syrmia.com> Signed-off-by: Laurent Vivier <laurent@vivier.eu>
Diffstat (limited to 'linux-user/qemu.h')
0 files changed, 0 insertions, 0 deletions