ID: 31201 Updated by: [EMAIL PROTECTED] Reported By: borbarad at gmxpro dot net -Status: Open +Status: Feedback Bug Type: COM related Operating System: Windows 2000 Server PHP Version: 4.3.10 New Comment:
Please try using this CVS snapshot: http://snaps.php.net/php4-STABLE-latest.tar.gz For Windows: http://snaps.php.net/win32/php4-win32-STABLE-latest.zip Previous Comments: ------------------------------------------------------------------------ [2004-12-21 11:26:52] borbarad at gmxpro dot net > Are you sure you upgraded correctly and have no stale DLLs? Yes. I can rule out, that there are any older DLLs in the %PATH% which may be loaded earlier. From Apache I load the php4ts.dll giving the complete path and at command-line there's no place where such a DLL could hide. Maybe it's the symptom of another change :-/ We are going to upgrade to PHP 5 anyway, but we'll have to review all our scripts. Therefore we are still using 4.3.10. ------------------------------------------------------------------------ [2004-12-21 02:08:12] [EMAIL PROTECTED] The 4.3 COM codebase hasn't changed in the latest release, so this sounds fishy. Are you sure you upgraded correctly and have no stale DLLs? If you continue to have COM related problems, we highly recommend that you upgrade to PHP 5 where the COM support has been completely rewritten. We don't support COM in PHP 4 any longer (although you might be able to sponsor one of the developers to work on it if you're really serious). ------------------------------------------------------------------------ [2004-12-20 14:47:04] borbarad at gmxpro dot net Description: ------------ When calling new COM() in PHP 4.3.10 the call will raise an exception due to read of memory at a location too close to NULL (same memory page). This problem occurred only in the latest PHP release. It does not apply to 4.3.9! Actually because it broke some of our scripts we recognized this as a problem. Reproduce code: --------------- //--------------------------------------------------- function GetDomainMachines($DomainName) { // Get the domain object ... $objDomain = new COM("WinNT://".$DomainName); // List all objects and ... while($obj = $objDomain->Next()) // ... filter for computers if ($obj->Class == "Computer"){ $arr[] = $obj->Name; } return $arr; } /* Give a valid domain name as the parameter, then call the function and dump the array contents */ Expected result: ---------------- It will return all machine names of domain members in the hash. Instead of filtering for type "Computer" one may use "User" and give the local machine as the "DomainName" parameter. In this case it should even work on the local machine and will return all users of the local machine. Actual result: -------------- Exception (messagebox, not even as a PHP error). Find a screenshot here: http://www.erm.tu-cottbus.de/~schneol/php/Screenshot0001.png Note, that regardless which object you try to instantiate you'll always fail reading at 0x0000006c, not different locations in memory. ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=31201&edit=1