components/net-snmp/patches/054.20479968.net-snmp-config.in.patch
author James Chang <james.c.chang@Oracle.COM>
Fri, 02 Oct 2015 10:50:45 -0700
changeset 4915 48f204cc245c
parent 4143 bba1a37c4d02
permissions -rw-r--r--
PSARC/2015/333 EOL of grails 21494758 Removal of GRAILS from Solaris 21494777 Removal of GRAILS man page from Solaris

This patch fixes a Solaris specific issue related to user creation
in snmpv3. The patch has been submitted to the community but has
not been accepted yet.

The details can be found in the following location
https://sourceforge.net/p/net-snmp/bugs/2607

--- a/net-snmp-config.in	Fri Jun 29 15:18:27 2007
+++ b/net-snmp-config.in	Wed Apr  1 22:08:50 2015
@@ -191,7 +191,7 @@
       ;;
     ####################################################
     --create-snmpv3-user)
-      if @PSCMD@ | egrep ' snmpd *$' > /dev/null 2>&1 ; then
+      if " $PSPROG -z `zonename` | egrep ' snmpd *$' " > /dev/null 2>&1 ; then
          echo "Apparently at least one snmpd demon is already running."
          echo "You must stop them in order to use this command."
          exit 1
@@ -656,7 +656,9 @@
       usage="yes"
       ;;
   esac
-  shift
+  if test "$#" -gt 0 ; then
+    shift
+  fi
   done
 fi