aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/ahoy/emulator.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/ahoy/emulator.c b/src/ahoy/emulator.c
index 100d70c..1298ea0 100644
--- a/src/ahoy/emulator.c
+++ b/src/ahoy/emulator.c
@@ -84,7 +84,8 @@ emulate(struct u8view prog)
PC = MEM_RESERVED;
memcpy(mem + PC, prog.p, prog.len);
- clock_gettime(CLOCK_REALTIME, &tp);
+ if (clock_gettime(CLOCK_REALTIME, &tp) == -1)
+ die("clock_gettime");
srand(tp.tv_sec ^ tp.tv_nsec);
for (;; PC += 2) {