ID: 46065 Updated by: [EMAIL PROTECTED] -Summary: Unexpected behavior snmp_set_quick_print() Reported By: php at painfullscratch dot nl Status: Open Bug Type: SNMP related Operating System: Linux PHP Version: 5.2.6 New Comment:
It's pretty simple issue, propably need to add some netsnmp shutdown function in RINIT which clears all the settings between requests. Previous Comments: ------------------------------------------------------------------------ [2008-09-12 13:27:09] php at painfullscratch dot nl Description: ------------ When PHP runs under Apache and snmp_set_quick_print(TRUE) is issued, the behavior of all SNMP-related functions will be "quick print" for the lifetime of the PID. NET-SNMP Support => enabled NET-SNMP Version => 5.4.1 PHP version: 5.2.4 There are two possibilities: 1) This behavior is "by design": If this is the case I think the manual page for snmp_set_quick_print() needs a warning for this behavior. 2) This is a bug: For each PID the behavior should be (re)set to the default behavior after execution of the script. Reproduce code: --------------- [EMAIL PROTECTED]:/tmp$ sudo /etc/init.d/apache2 restart > /dev/null 2>&1 [EMAIL PROTECTED]:/tmp$ for (( i=0; i<5; i++ )) ; do links -dump http://localhost/snmp_get_quick_print.php; done snmp_get_quick_print: '' | pid: '9402' snmp_get_quick_print: '' | pid: '9403' snmp_get_quick_print: '' | pid: '9404' snmp_get_quick_print: '' | pid: '9405' snmp_get_quick_print: '' | pid: '9406' [EMAIL PROTECTED]:/tmp$ links -dump http://localhost/snmp_set_quick_print.php snmp_set_quick_print: '' | pid: '9406' [EMAIL PROTECTED]:/tmp$ for (( i=0; i<5; i++ )) ; do links -dump http://localhost/snmp_get_quick_print.php; done snmp_get_quick_print: '' | pid: '9403' snmp_get_quick_print: '' | pid: '9404' snmp_get_quick_print: '' | pid: '9446' snmp_get_quick_print: '' | pid: '9405' snmp_get_quick_print: '1' | pid: '9406' ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=46065&edit=1
