Ignore:
Timestamp:
23/08/06 15:20:05 (14 years ago)
Author:
spascoe
Message:

Implemented two hooks in the bbftpd source that allow
python code to be executed before and afer a fork(). This is needed
to reset python logging and will probably be usefull for other things
in the future.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • TI05-delivery/trunk/src/bbftp-server-3.2.0/bbftpd/bbftpd_daemon.c

    r1358 r1448  
    4949#include <stdio.h> 
    5050#include <bbftpd_private_log.h> 
     51#include <bbftpd_private_fork.h> 
    5152#include <sys/socket.h> 
    5253#if TIME_WITH_SYS_TIME 
     
    132133    } 
    133134    /* Fork - so I'm not the owner of the process group any more */ 
    134     retcode = fork(); 
     135    retcode = bbftpd_fork(); 
    135136    if (retcode < 0) { 
    136137        bbftpd_log(BBFTPD_ERR, "Cannot fork %s",strerror(errno)); 
     
    208209        } 
    209210            /* Fork off a handler */ 
    210         pid = fork(); 
     211        pid = bbftpd_fork(); 
    211212        if (pid < 0) { 
    212213            bbftpd_log(BBFTPD_ERR, "failed to fork: %s",strerror(errno)); 
Note: See TracChangeset for help on using the changeset viewer.