projects
/
umurmur.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0cd54c5
)
Patch from tilman2: Open PID file with O_EXCL
author
fatbob313
<martin@fatbob.nu>
Thu, 20 Jan 2011 08:24:21 +0000
(08:24 +0000)
committer
fatbob313
<martin@fatbob.nu>
Thu, 20 Jan 2011 08:24:21 +0000
(08:24 +0000)
src/main.c
patch
|
blob
|
history
diff --git
a/src/main.c
b/src/main.c
index 70358e61ad88ebb71215f4f3041760e546044515..1b92f50797e931a0807de2ed5f91548844ec9304 100644
(file)
--- a/
src/main.c
+++ b/
src/main.c
@@
-60,7
+60,7
@@
void lockfile(const char *pidfile)
int lfp;
char str[16];
- lfp = open(pidfile, O_RDWR|O_CREAT, 0640);
+ lfp = open(pidfile, O_RDWR|O_CREAT
|O_EXCL
, 0640);
if (lfp < 0)
Log_fatal("Cannot open PID-file %s for writing", pidfile);