Lines Matching refs:ctlfd
1291 static int ctlfd = -1; variable
1327 if ((ctlfd = open("/proc/self/ctl", O_WRONLY)) < 0 || in init_watch()
1328 fstat(ctlfd, &ctlstatb) != 0) { in init_watch()
1329 if (ctlfd >= 0) in init_watch()
1330 (void) close(ctlfd); in init_watch()
1331 ctlfd = -1; in init_watch()
1336 (void) fcntl(ctlfd, F_SETFD, 1); in init_watch()
1359 (void) write(ctlfd, &ctl, sizeof (ctl)); in init_watch()
1370 if (ctlfd < 0) /* first time */ in nowatch()
1372 else if (fstat(ctlfd, &statb) != 0 || in nowatch()
1379 if ((ctlfd = open("/proc/self/ctl", O_WRONLY)) < 0 || in nowatch()
1380 fstat(ctlfd, &ctlstatb) != 0) { in nowatch()
1381 if (ctlfd >= 0) in nowatch()
1382 (void) close(ctlfd); in nowatch()
1383 ctlfd = -1; in nowatch()
1388 (void) fcntl(ctlfd, F_SETFD, 1); in nowatch()
1397 (void) close(ctlfd); in nowatch()
1398 ctlfd = -1; in nowatch()
1424 (void) write(ctlfd, &ctl, sizeof (ctl)); in protect()
1441 (void) write(ctlfd, &ctl, sizeof (ctl)); in unprotect()