r3804 call mktemp with six X's in template to satisfy debianutils (by Rafael Ganascim)
authorDenis Ovsienko <infrastation@yandex.ru>
Thu, 10 Jun 2010 17:55:07 +0000 (17:55 +0000)
committerDenis Ovsienko <infrastation@yandex.ru>
Thu, 10 Jun 2010 17:55:07 +0000 (17:55 +0000)
ChangeLog
gateways/deviceconfig/fdry5.connector
gateways/deviceconfig/ios12.connector
gateways/deviceconfig/vrp53.connector
gateways/deviceconfig/xos12.connector
gateways/switchvlans/cisco.connector
gateways/switchvlans/main

index cfc6f85..02ddca7 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,5 @@
+0.18.3
+       bugfix: fix mktemp not working on Slackware (by Rafael Ganascim)
 0.18.2 2010-06-10
        bugfix: don't restore last opened tab, which won't be permitted anyway
        update: completely switch to PDO prepared queries (#120)
index bf62014..fa4aef0 100755 (executable)
@@ -43,7 +43,7 @@ prepare_connect_commands()
 }
 
 MYNAME=`basename $0`
-SESSION=`mktemp /tmp/$MYNAME.XXXX`
+SESSION=`mktemp /tmp/$MYNAME.XXXXXX`
 [ -f "$SESSION" ] || exit 5
 prepare_connect_commands $ENDPOINT
 case $COMMAND in
index e260dfd..8b016fd 100755 (executable)
@@ -44,7 +44,7 @@ prepare_connect_commands()
 }
 
 MYNAME=`basename $0`
-SESSION=`mktemp /tmp/$MYNAME.XXXX`
+SESSION=`mktemp /tmp/$MYNAME.XXXXXX`
 [ -f "$SESSION" ] || exit 5
 prepare_connect_commands $ENDPOINT
 case $COMMAND in
index 5264ade..2b578c4 100755 (executable)
@@ -43,7 +43,7 @@ prepare_connect_commands()
 }
 
 MYNAME=`basename $0`
-SESSION=`mktemp /tmp/$MYNAME.XXXX`
+SESSION=`mktemp /tmp/$MYNAME.XXXXXX`
 [ -f "$SESSION" ] || exit 5
 prepare_connect_commands $ENDPOINT
 case $COMMAND in
index da507e9..4b16804 100755 (executable)
@@ -40,7 +40,7 @@ prepare_connect_commands()
 }
 
 MYNAME=`basename $0`
-SESSION=`mktemp /tmp/$MYNAME.XXXX`
+SESSION=`mktemp /tmp/$MYNAME.XXXXXX`
 [ -f "$SESSION" ] || exit 5
 prepare_connect_commands $ENDPOINT
 case $COMMAND in
index 57f8bb7..17d5cc8 100755 (executable)
@@ -166,17 +166,17 @@ remove_tempfiles()
 create_tempfiles()
 {
        # This one is for VLAN list.
-       CMDS1=`mktemp /tmp/cisco.connector.XXXX`
+       CMDS1=`mktemp /tmp/cisco.connector.XXXXXX`
        # And this one holds ports list...
-       CMDS2=`mktemp /tmp/cisco.connector.XXXX`
+       CMDS2=`mktemp /tmp/cisco.connector.XXXXXX`
        # ...and one more for MAC address table
-       CMDS3=`mktemp /tmp/cisco.connector.XXXX`
+       CMDS3=`mktemp /tmp/cisco.connector.XXXXXX`
        # The following are buffers to hold the whole switch output
        # before filtering.
-       OUT1=`mktemp /tmp/cisco.connector.XXXX`
-       OUT2a=`mktemp /tmp/cisco.connector.XXXX`
-       OUT2b=`mktemp /tmp/cisco.connector.XXXX`
-       OUT3=`mktemp /tmp/cisco.connector.XXXX`
+       OUT1=`mktemp /tmp/cisco.connector.XXXXXX`
+       OUT2a=`mktemp /tmp/cisco.connector.XXXXXX`
+       OUT2b=`mktemp /tmp/cisco.connector.XXXXXX`
+       OUT3=`mktemp /tmp/cisco.connector.XXXXXX`
        [ -f "$CMDS1" -a -f "$CMDS2" -a -f "$CMDS3" -a -f "$OUT1" -a -f "$OUT2a" -a -f "$OUT2b" -a -f "$OUT3" ] && return
        echo "E!connector cannot create tempfiles" >> "$FILE2"
        remove_tempfiles
index 6399abd..3e977b0 100755 (executable)
@@ -84,18 +84,18 @@ do_connect()
        esac
 
        # prepare temp files
-       PORTINFO=`mktemp /tmp/racktables.XXXX`
+       PORTINFO=`mktemp /tmp/racktables.XXXXXX`
        if ! [ -f "$PORTINFO" ]; then
                echo 'ERR!could not create portinfo tmpfile'
                return
        fi
-       VLANINFO=`mktemp /tmp/racktables.XXXX`
+       VLANINFO=`mktemp /tmp/racktables.XXXXXX`
        if ! [ -f "$VLANINFO" ]; then
                echo 'ERR!could not create vlaninfo tmpfile'
                rm -f "$PORTINFO"
                return
        fi
-       MACINFO=`mktemp /tmp/racktables.XXXX`
+       MACINFO=`mktemp /tmp/racktables.XXXXXX`
        if ! [ -f "$MACINFO" ]; then
                echo 'ERR!could not create MACinfo tmpfile'
                rm -f "$PORTINFO" "$VLANINFO"
@@ -141,8 +141,8 @@ do_set()
                echo 'ERR!missing set argument'
                return
        fi
-       local REQUESTS=`mktemp /tmp/racktables.XXXX`
-       local REPLIES=`mktemp /tmp/racktables.XXXX`
+       local REQUESTS=`mktemp /tmp/racktables.XXXXXX`
+       local REPLIES=`mktemp /tmp/racktables.XXXXXX`
        echo $1 | tr ';' '\n' | while read setexpr; do
                portname=`echo $setexpr | cut -s -d'=' -f1`
                newvlan=`echo $setexpr | cut -s -d'=' -f2`