From: nesslage at mwsc dot edu Operating system: RH Linux 7.3 PHP version: 4.3.3 PHP Bug Type: SNMP related Bug description: SNMP Session not closed
Description: ------------ In ext/snmp/snmp.c, it is possible to exit php_snmp_internal without closing the snmp session when performing an snmpget. This leads to 'too many open files' errors on a script with many snmpget requests. Reproduce code: --------------- ext/snmp/snmp.c: Lines 427 to 430 if (st == 1) { *return_value = *snmpval; zval_copy_ctor(return_value); return; should be changed to: if (st == 1) { *return_value = *snmpval; zval_copy_ctor(return_value); snmp_close(ss); return; Expected result: ---------------- No more 'too many open files' errors. Actual result: -------------- No more 'too many open files' errors. -- Edit bug report at http://bugs.php.net/?id=25636&edit=1 -- Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=25636&r=trysnapshot4 Try a CVS snapshot (php5): http://bugs.php.net/fix.php?id=25636&r=trysnapshot5 Fixed in CVS: http://bugs.php.net/fix.php?id=25636&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=25636&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=25636&r=needtrace Try newer version: http://bugs.php.net/fix.php?id=25636&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=25636&r=support Expected behavior: http://bugs.php.net/fix.php?id=25636&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=25636&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=25636&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=25636&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=25636&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=25636&r=dst IIS Stability: http://bugs.php.net/fix.php?id=25636&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=25636&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=25636&r=float