diff options
Diffstat (limited to 'tests/threads/accept/cancel.zc')
| -rw-r--r-- | tests/threads/accept/cancel.zc | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/threads/accept/cancel.zc b/tests/threads/accept/cancel.zc new file mode 100644 index 0000000..db4f7c7 --- /dev/null +++ b/tests/threads/accept/cancel.zc @@ -0,0 +1,8 @@ +namespace; +include rt; +unchecked fn main() { + int fd = 0; + let context = rt.syscall(51, fn() { while (1) {} return 0; } as word, &fd, 0); + rt.syscall(48, 20, 0, 0); let started = rt.syscall(50, 0, 0, 0); + rt.put_n(rt.syscall(52, context, 1, 0)); rt.put_c(10); rt.put_n(rt.syscall(50, 0, 0, 0) - started); rt.put_c(10); return 0; +} |
