diff options
Diffstat (limited to 'target/nios2')
-rw-r--r-- | target/nios2/nios2-semi.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/target/nios2/nios2-semi.c b/target/nios2/nios2-semi.c index fe5598bae4..5a7ad0c710 100644 --- a/target/nios2/nios2-semi.c +++ b/target/nios2/nios2-semi.c @@ -403,7 +403,7 @@ void do_nios2_semihosting(CPUNios2State *env) qemu_timeval tv; struct gdb_timeval *p; result = qemu_gettimeofday(&tv); - if (result != 0) { + if (result == 0) { p = lock_user(VERIFY_WRITE, arg0, sizeof(struct gdb_timeval), 0); if (!p) { |