Branch Coverage

c/io.c
Criterion Covered Total %
branch 63 98 64.2


line true false branch
30 0 3809 if (WaTMPERLCB(ev))
32 0 3809 PE_RING_DETACH(&ev->ioring);
42 3801 6 if (SvOK(ev->handle))
3801 0 if (SvOK(ev->handle))
0 3801 if (SvOK(ev->handle))
43 6 0 ev->fd = pe_sys_fileno(ev->handle, SvPV(ev->base.desc, n_a));
49 6 3801 if (ev->fd >= 0 && (ev->poll & ~PE_T)) {
5 1 if (ev->fd >= 0 && (ev->poll & ~PE_T)) {
50 0 5 if (!ev->base.callback)
58 3800 7 if (ev->timeout) {
59 0 3800 if (!ev->base.callback && !ev->tm_callback) {
0 0 if (!ev->base.callback && !ev->tm_callback) {
70 3 3804 return ok? 0 : "because there is nothing to watch";
76 5 3799 if (!PE_RING_EMPTY(&ev->ioring)) {
78 5 0 PE_RING_DETACH(&ev->ioring);
88 1583 21 if (left < IntervalEpsilon) {
90 1581 2 if (WaREPEAT(wa)) {
99 3 1580 if (wa->tm_callback) {
100 3 0 if (WaTMPERLCB(wa)) {
118 3808 1 if (!WaPOLLING(ev)) return;
133 6 0 if (nval) {
135 0 6 if (io->timeout) nev |= PE_T;
137 3 3 if (io->poll != nev) {
144 0 6 XPUSHs(sv_2mortal(events_mask_2sv(io->poll)));
151 6 110088 if (nval) {
160 0 110094 XPUSHs(io->handle);
167 3799 1 if (nval) {
168 0 3799 io->timeout = SvOK(nval)? SvNV(nval) : 0; /*undef is ok*/
0 0 io->timeout = SvOK(nval)? SvNV(nval) : 0; /*undef is ok*/
0 0 io->timeout = SvOK(nval)? SvNV(nval) : 0; /*undef is ok*/
6 3793 io->timeout = SvOK(nval)? SvNV(nval) : 0; /*undef is ok*/
173 0 3800 XPUSHs(sv_2mortal(newSVnv(io->timeout)));
180 6 0 if (nval) {
184 3 3 if (WaTMPERLCB(ev))
186 3 3 if (!SvOK(nval)) {
3 0 if (!SvOK(nval)) {
3 0 if (!SvOK(nval)) {
190 3 0 } else if (SvROK(nval) && (SvTYPE(sv=SvRV(nval)) == SVt_PVCV)) {
1 2 } else if (SvROK(nval) && (SvTYPE(sv=SvRV(nval)) == SVt_PVCV)) {
193 2 0 } else if (SvROK(nval) &&
2 0 } else if (SvROK(nval) &&
194 2 0 (SvTYPE(av=(AV*)SvRV(nval)) == SVt_PVAV) &&
195 2 0 av_len(av) == 1 &&
200 0 0 if (SvIV(DebugLevel) >= 2)
0 0 if (SvIV(DebugLevel) >= 2)
204 3 3 if (old)
209 3 3 (SV*) io->tm_callback :
212 0 3 io->tm_callback, io->tm_ext_data)) :
215 0 6 XPUSHs(ret);