|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2005-04-15 14:04 UTC] sniper@php.net
[2005-04-23 23:31 UTC] sniper@php.net
[2005-04-25 08:27 UTC] dejan at akton dot si
[2005-04-25 23:57 UTC] sniper@php.net
[2005-04-26 14:17 UTC] dejan at akton dot si
[2005-04-29 01:10 UTC] sniper@php.net
[2005-05-10 15:30 UTC] sniper@php.net
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Mon Oct 27 10:00:01 2025 UTC |
Description: ------------ In 4.3.11 someone added a PHP_MSHUTDOWN(snmp) to ext/snmp/snmp.c extension. I'm not so familiar with the PHP source it self, but here's what I see. In CLI version, PHP_MINIT() and PHP_MSHUTDOWN works as expected, when script starts PHP_MINIT() is called which initialized the snmp API and when script is done, PHP_MSHUTDOWN is called, which clears the instance of snmp API. But under Apache there's a problem. When apache starts, it calls PHP_MINIT() but it also calls PHP_MSHUTDOWN, which clears the instance. When you request a script via Apache, the PHP_MINIT() is not called and SNMP Api is not initialized and I receive strange errors. Reproduce code: --------------- $foo = snmpget('127.0.0.1', 'public', 'system.SysContact.0'); Expected result: ---------------- Output from system.SysContect.0 Actual result: -------------- Invalid OID and invalid host. From the SNMP API I receive: No support for requested transport domain "udp". And this is because the API was not initialized and transport domains were not loaded!