mirror of
https://github.com/FirebirdSQL/firebird.git
synced 2025-01-24 09:23:03 +01:00
Better way to delete pidfile, thanks to Claudio
This commit is contained in:
parent
9e23d61b99
commit
d88aaa5b92
@ -15,7 +15,7 @@
|
|||||||
*
|
*
|
||||||
* All Rights Reserved.
|
* All Rights Reserved.
|
||||||
* Contributor(s): ______________________________________.
|
* Contributor(s): ______________________________________.
|
||||||
* $Id: guard.cpp,v 1.8.12.2 2006-04-16 15:29:20 asfernandes Exp $
|
* $Id: guard.cpp,v 1.8.12.3 2006-04-18 08:56:34 alexpeshkoff Exp $
|
||||||
*/
|
*/
|
||||||
/* contains the main() and not shared routines for ibguard */
|
/* contains the main() and not shared routines for ibguard */
|
||||||
|
|
||||||
@ -39,10 +39,6 @@
|
|||||||
#include <errno.h>
|
#include <errno.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef HAVE_UNISTD_H
|
|
||||||
#include <unistd.h>
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#include "../jrd/common.h"
|
#include "../jrd/common.h"
|
||||||
#include "../jrd/divorce.h"
|
#include "../jrd/divorce.h"
|
||||||
#include "../jrd/isc_proto.h"
|
#include "../jrd/isc_proto.h"
|
||||||
@ -228,11 +224,9 @@ int CLIB_ROUTINE main( int argc, char **argv)
|
|||||||
}
|
}
|
||||||
} while (!done);
|
} while (!done);
|
||||||
|
|
||||||
#ifdef HAVE_UNISTD_H
|
|
||||||
if (pidfilename) {
|
if (pidfilename) {
|
||||||
unlink(pidfilename);
|
remove(pidfilename);
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
UTIL_ex_unlock(fd_guard);
|
UTIL_ex_unlock(fd_guard);
|
||||||
exit(0);
|
exit(0);
|
||||||
} /* main */
|
} /* main */
|
||||||
|
Loading…
Reference in New Issue
Block a user