File: safe_asterisk-config

package info (click to toggle)
asterisk 1%3A1.6.2.9-2%2Bsqueeze12
  • links: PTS, VCS
  • area: main
  • in suites: squeeze
  • size: 67,296 kB
  • ctags: 65,026
  • sloc: ansic: 327,660; sh: 11,153; cpp: 5,940; perl: 3,078; makefile: 2,594; yacc: 2,140; asm: 642; xml: 309; sql: 290; tcl: 113; php: 62
file content (28 lines) | stat: -rw-r--r-- 871 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
Subject: use /etc/default/settings for configuring safe_asterisk (vendor specific)
Author: Faidon Liambotis <paravoid@debian.org>
Bug-Debian: http://bugs.debian.org/381786
Last-Update: 2010-02-14

Use ASTSAFE_TTY and ASTSAFE_CONSOLE from /etc/default/asterisk to configure
safe_asterisk.

--- a/contrib/scripts/safe_asterisk
+++ b/contrib/scripts/safe_asterisk
@@ -112,7 +116,7 @@ ulimit -c unlimited
 # Don't fork when running "safely"
 #
 ASTARGS=""
-if test "x$TTY" != "x" ; then
+if test "x$TTY" != "xno" ; then
 	if test -c /dev/tty${TTY} ; then
 		TTY=tty${TTY}
 	elif test -c /dev/vc/${TTY} ; then
@@ -152,7 +156,7 @@ run_asterisk()
 {
 	while :; do 
 
-		if test "x$TTY" != "x" ; then
+		if test "x$TTY" != "xno" ; then
 			cd /tmp
 			stty sane < /dev/${TTY}
 			nice -n $PRIORITY ${ASTSBINDIR}/asterisk -f ${CLIARGS} ${ASTARGS} > /dev/${TTY} 2>&1 < /dev/${TTY}