aboutsummaryrefslogtreecommitdiff
path: root/tests/threads/accept/cancel.zc
blob: db4f7c7bd29ec77dbd81d3d833b9d5680743b301 (plain) (blame)
1
2
3
4
5
6
7
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;
}