[zaptel-commits] tzafrir: branch 1.4 r1590 - in /branches/1.4/xpp:
init_card_3_23 init_card_4_23
zaptel-commits at lists.digium.com
zaptel-commits at lists.digium.com
Sat Nov 11 07:34:47 MST 2006
Author: tzafrir
Date: Sat Nov 11 08:34:45 2006
New Revision: 1590
URL: http://svn.digium.com/view/zaptel?view=rev&rev=1590
Log:
init_card[34]_23: merge from 2654,2655.
* Redirect stderr to /dev/null.
Without any redirection, it may fail with exitval=4 .
Probably, fd 2 is closed and the shell (or sed which is
used in the scripts) tries to write to it (or do some other
I/O related syscall) which fails.
* make XPP_BASE handling identical in the two scripts.
Modified:
branches/1.4/xpp/init_card_3_23
branches/1.4/xpp/init_card_4_23
Modified: branches/1.4/xpp/init_card_3_23
URL: http://svn.digium.com/view/zaptel/branches/1.4/xpp/init_card_3_23?view=diff&rev=1590&r1=1589&r2=1590
==============================================================================
--- branches/1.4/xpp/init_card_3_23 (original)
+++ branches/1.4/xpp/init_card_3_23 Sat Nov 11 08:34:45 2006
@@ -42,12 +42,17 @@
me=`basename $0`
INIT_DIR=`dirname $0`
-export XPP_BASE=/proc/xpp
+XPP_BASE=/proc/xpp
+export XPP_BASE
LOGGER="logger -s -t $me"
+# Always redirect stderr somewhere, otherwise the shell script will die
+# when it tries to do I/O related stuff on closed file descriptor.
+# Our default is to throw it down the bit-bucket.
+exec 2> /dev/null
## If you wish to trace this script:
#exec 2> /tmp/xpp_init_$XPD_NAME
-## Altenativly, if you have multiple XPDs:
+## Altenativly, if you have multiple XBUS'es:
#exec 2> /tmp/xpp_init_$XBUS_NAME_$XPD_NAME
#set -x
Modified: branches/1.4/xpp/init_card_4_23
URL: http://svn.digium.com/view/zaptel/branches/1.4/xpp/init_card_4_23?view=diff&rev=1590&r1=1589&r2=1590
==============================================================================
--- branches/1.4/xpp/init_card_4_23 (original)
+++ branches/1.4/xpp/init_card_4_23 Sat Nov 11 08:34:45 2006
@@ -44,9 +44,13 @@
export XPP_BASE
LOGGER="logger -s -t $me"
+# Always redirect stderr somewhere, otherwise the shell script will die
+# when it tries to do I/O related stuff on closed file descriptor.
+# Our default is to throw it down the bit-bucket.
+exec 2> /dev/null
## If you wish to trace this script:
#exec 2> /tmp/xpp_init_$XPD_NAME
-## Altenativly, if you have multiple XPDs:
+## Altenativly, if you have multiple XBUS'es:
#exec 2> /tmp/xpp_init_$XBUS_NAME_$XPD_NAME
#set -x
More information about the zaptel-commits
mailing list