summaryrefslogtreecommitdiff
path: root/main/asterisk.c
diff options
context:
space:
mode:
authorTilghman Lesher <tilghman@meg.abyt.es>2010-04-02 20:19:01 +0000
committerTilghman Lesher <tilghman@meg.abyt.es>2010-04-02 20:19:01 +0000
commit3c6c8796814cfac5e58a0e1d6e0280cc8e36e9b7 (patch)
tree044574fb3bce8ce9f2f262f7cd7c46518335a498 /main/asterisk.c
parent2be88e05c043e8abc1b6a3c94c4699859a7adf68 (diff)
Pass the PID of the Asterisk process, not the PID of the canary.
(closes issue #17065) Reported by: globalnetinc Patches: astcanary.patch uploaded by makoto (license 38) Tested by: frawd, globalnetinc git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@255952 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'main/asterisk.c')
-rw-r--r--main/asterisk.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/main/asterisk.c b/main/asterisk.c
index 93d52c053..8f557f736 100644
--- a/main/asterisk.c
+++ b/main/asterisk.c
@@ -3530,7 +3530,7 @@ int main(int argc, char *argv[])
ast_close_fds_above_n(0);
ast_set_priority(0);
- snprintf(ppid, sizeof(ppid), "%d", (int) getpid());
+ snprintf(ppid, sizeof(ppid), "%d", (int) ast_mainpid);
execlp("astcanary", "astcanary", canary_filename, ppid, (char *)NULL);