From: motion4u at hotmail dot com Operating system: Windows 2000 Advanced PHP version: 4.3.6 PHP Bug Type: IIS related Bug description: function symlink() crash under windows
Description: ------------ Create and Manipulate NTFS Junction Points doesn't work in PHP but it was solved by www.sysinternals.com. They also offer the c-code free for download. I have tested it and it works very well. You can download the free source code there: http://www.sysinternals.com/files/jnctnsrc.zip Reproduce code: --------------- $letters = 'abcdefghijklmnopqrstuvwxyz'; srand((double) microtime() * 1000000); $string = ''; for ($i = 1; $i <= rand(4,12); $i++) { $q = rand(1,24); $string = $string . $letters[$q]; } //----- this part can't work under windows $handle = opendir($downloaddir); while ($dir = readdir($handle)) { if (is_dir($downloaddir . $dir)){ if ($dir != "." && $dir != ".."){ @unlink($downloaddir . $dir . "/" . $filename); @rmdir($downloaddir . $dir); } } } closedir($handle); //------ mkdir($downloaddir . $string, 0777); // here symlink produce browser crash under windows symlink($safedir . $filename, $downloaddir . $string . "/" . $filename); Header("Location: ".$downloadURL.$string. "/" . $filename); Expected result: ---------------- start downloading but produce browser crash -- Edit bug report at http://bugs.php.net/?id=28279&edit=1 -- Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=28279&r=trysnapshot4 Try a CVS snapshot (php5): http://bugs.php.net/fix.php?id=28279&r=trysnapshot5 Fixed in CVS: http://bugs.php.net/fix.php?id=28279&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=28279&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=28279&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=28279&r=needscript Try newer version: http://bugs.php.net/fix.php?id=28279&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=28279&r=support Expected behavior: http://bugs.php.net/fix.php?id=28279&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=28279&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=28279&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=28279&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=28279&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=28279&r=dst IIS Stability: http://bugs.php.net/fix.php?id=28279&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=28279&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=28279&r=float
