git.samba.org
/
sfrench
/
samba-autobuild
/
.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(from parent 1:
0b5e354
)
lib/util: don't SMB_ASSERT() in process_exists_by_pid()
author
Stefan Metzmacher
<metze@samba.org>
Wed, 22 Aug 2012 15:52:01 +0000
(17:52 +0200)
committer
Stefan Metzmacher
<metze@samba.org>
Fri, 24 Aug 2012 11:43:32 +0000
(13:43 +0200)
Just return false...
metze
lib/util/util.c
patch
|
blob
|
history
diff --git
a/lib/util/util.c
b/lib/util/util.c
index 100d3d84ab377c044ef3887bc658ccbea1931227..b50d28afcf34b9c2df1f25891125733f0a3072d2 100644
(file)
--- a/
lib/util/util.c
+++ b/
lib/util/util.c
@@
-286,7
+286,9
@@
_PUBLIC_ bool process_exists_by_pid(pid_t pid)
{
/* Doing kill with a non-positive pid causes messages to be
* sent to places we don't want. */
- SMB_ASSERT(pid > 0);
+ if (pid <= 0) {
+ return false;
+ }
return(kill(pid,0) == 0 || errno != ESRCH);
}