updated on Sun Jan 22 08:00:21 UTC 2012
[aur-mirror.git] / pxe / 02-lockfile.patch
blobf2f13b0bf6546fd6574f0fcc88f283c1b7618b1e
1 diff -Naur pxe-1.4.2.orig/autoconf.h.in pxe-1.4.2/autoconf.h.in
2 --- pxe-1.4.2.orig/autoconf.h.in 2002-08-22 18:06:11.000000000 +0000
3 +++ pxe-1.4.2/autoconf.h.in 2006-07-22 19:50:33.000000000 +0000
4 @@ -61,7 +61,7 @@
5 /* should not need to change from here onwards */
7 /* the lock file */
8 -#define LOCKFILE "/tmp/pxe.pid"
9 +#define LOCKFILE "/var/run/pxe/pxe.pid"
11 #define DEF_MULTI_BOOT 0xe0000102
12 #define DEF_ADDR "0.0.0.0"
13 diff -Naur pxe-1.4.2.orig/pxe.cc pxe-1.4.2/pxe.cc
14 --- pxe-1.4.2.orig/pxe.cc 2003-02-02 12:39:26.000000000 +0000
15 +++ pxe-1.4.2/pxe.cc 2006-07-22 19:50:33.000000000 +0000
16 @@ -312,7 +312,7 @@
17 umask(0);
19 // write out the pid
20 - sprintf(pidnum, "%ld", (long)getpid());
21 + sprintf(pidnum, "%ld\n", (long)getpid());
22 if(write(chk, pidnum, strlen(pidnum)) !=
23 (ssize_t)strlen(pidnum)) {
24 std::cerr << "Unable to write lockfile\n";