FreeBSD Bugzilla – Attachment 185125 Details for
Bug 221271
net/asterisk13: rc script fails on "restart" in some occasions
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Asterisk rc.script fixes
asterisk.diff (text/plain), 1.49 KB, created by
Guido Falsi
on 2017-08-07 10:50:36 UTC
(
hide
)
Description:
Asterisk rc.script fixes
Filename:
MIME Type:
Creator:
Guido Falsi
Created:
2017-08-07 10:50:36 UTC
Size:
1.49 KB
patch
obsolete
>Index: Makefile >=================================================================== >--- Makefile (revision 447489) >+++ Makefile (working copy) >@@ -2,6 +2,7 @@ > > PORTNAME= asterisk > PORTVERSION= 13.17.0 >+PORTREVISION= 1 > CATEGORIES= net > MASTER_SITES= http://downloads.asterisk.org/pub/telephony/%SUBDIR%/:DEFAULT,g729 > MASTER_SITE_SUBDIR= asterisk/ \ >Index: files/asterisk.in >=================================================================== >--- files/asterisk.in (revision 447489) >+++ files/asterisk.in (working copy) >@@ -17,6 +17,8 @@ > # Default is "-n" > # asterisk_pidfile (string): Location of the asterisk pid file > # Default is /var/run/asterisk/asterisk.pid >+# asterisk_stopsleep (int): Number of seconds to sleep before sending stop command >+# Default is 0, which disables it > # > > . /etc/rc.subr >@@ -31,6 +33,7 @@ > : ${asterisk_user:=%%ASTERISK_USER%%} > : ${asterisk_args=-n} > : ${asterisk_pidfile:=/var/run/asterisk/asterisk.pid} >+: ${asterisk_stopsleep:=0} > > extra_commands=reload > >@@ -52,13 +55,26 @@ > > asterisk_stop() > { >- echo 'Stopping asterisk' >+ if [ -z "$rc_pid" ]; then >+ [ -n "$rc_fast" ] && return 0 >+ _run_rc_notrunning >+ return 1 >+ fi >+ echo 'Stopping asterisk.' >+ if [ ${asterisk_stopsleep} > 0 ]; then >+ sleep ${asterisk_stopsleep} >+ fi > $command -nqrx 'core stop now' >+ wait_for_pids $rc_pid > } > > asterisk_reload() > { >- echo 'Reloading asterisk' >+ if [ -z "$rc_pid" ]; then >+ _run_rc_notrunning >+ return 1 >+ fi >+ echo 'Reloading asterisk.' > $command -nqrx 'reload' > } >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 221271
: 185125