summaryrefslogtreecommitdiffstats
path: root/source/lib/pidfile.c
diff options
context:
space:
mode:
authorGerald Carter <jerry@samba.org>2006-02-03 22:19:41 +0000
committerGerald Carter <jerry@samba.org>2006-02-03 22:19:41 +0000
commit5831715049f2d460ce42299963a5defdc160891b (patch)
tree19a0c31c817c9bc26fd53485b5348ab4af127a23 /source/lib/pidfile.c
parente24ac859e7964714ed3b543300aadf77955af5bf (diff)
downloadsamba-5831715049f2d460ce42299963a5defdc160891b.tar.gz
samba-5831715049f2d460ce42299963a5defdc160891b.tar.xz
samba-5831715049f2d460ce42299963a5defdc160891b.zip
r13316: Let the carnage begin....
Sync with trunk as off r13315
Diffstat (limited to 'source/lib/pidfile.c')
-rw-r--r--source/lib/pidfile.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/source/lib/pidfile.c b/source/lib/pidfile.c
index b041eb7f1b2..08e41083b59 100644
--- a/source/lib/pidfile.c
+++ b/source/lib/pidfile.c
@@ -32,7 +32,8 @@ pid_t pidfile_pid(const char *name)
{
int fd;
char pidstr[20];
- unsigned ret;
+ pid_t pid;
+ unsigned int ret;
pstring pidFile;
slprintf(pidFile, sizeof(pidFile)-1, "%s/%s.pid", lp_piddir(), name);
@@ -57,7 +58,8 @@ pid_t pidfile_pid(const char *name)
goto noproc;
}
- if (!process_exists_by_pid(ret)) {
+ pid = (pid_t)ret;
+ if (!process_exists_by_pid(pid)) {
goto noproc;
}