FreeBSD/contrib/bmake/meta.c
/*
 * The child calls this before doing anything.
 * It does not disturb our state.
 */
The child calls this before doing anything.
It does not disturb our state.
The child calls this before doing anything . It does not disturb our state .
void
meta_job_child(Job *job)
{
#ifdef USE_FILEMON
    BuildMon *pbm;
    if (job != NULL) {
	pbm = &job->bm;
    } else {
	pbm = &Mybm;
    }
    if (pbm->mfp != NULL) {
	close(fileno(pbm->mfp));
	if (useFilemon) {
	    pid_t pid;
	    pid = getpid();
	    if (ioctl(pbm->filemon_fd, FILEMON_SET_PID, &pid) < 0) {
		err(1, "Could not set filemon pid!");
	    }
	}
    }
#endif
}
void meta_job_child ( Job * job ) { #ifdef USE_FILEMON BuildMon * pbm ; if ( job != NULL ) { pbm = & job -> bm ; } else { pbm = & Mybm ; } if ( pbm -> mfp != NULL ) { close ( fileno ( pbm -> mfp ) ) ; if ( useFilemon ) { pid_t pid ; pid = getpid ( ) ; if ( ioctl ( pbm -> filemon_fd , FILEMON_SET_PID , & pid ) < 0 ) { err ( 1 , " " ) ; } } } #endif }
The child calls this before doing anything.
The child calls this before doing anything .