ref: 6cdf4cb5e83da3d89367cd2e2d8b1813b573146d
parent: 60d780e420499ff353979ad938a6b2204a8d1863
author: Sigrid Solveig Haflínudóttir <ftrvxmtrx@gmail.com>
date: Mon Jul 19 10:58:23 EDT 2021
use procdata instead of threaddata
--- a/hj264.c
+++ b/hj264.c
@@ -338,7 +338,7 @@
if(s != 0)
fprint(2, "%llud fps\n", nframes / s);
}
- h = *threaddata();
+ h = *procdata();
Bflush(&h->out);
threadexitsall(msg);
return 1;
@@ -441,9 +441,9 @@
h->rp.qp_max = 50;
h->rp.desired_frame_bytes = kbps*1000/8/fps;
}
- proccreate(encthread, h, mainstacksize);
- *threaddata() = h;
+ *procdata() = h;
threadnotify(done, 1);
+ proccreate(encthread, h, mainstacksize);
tstart = npe_nanosec();
for(nframes = 0;; nframes++){