#26051 [Opn->Bgs]: filetype() returns wrong type for device drivers

From: Date: Fri, 31 Oct 2003 13:38:18 +0000
Subject: #26051 [Opn->Bgs]: filetype() returns wrong type for device drivers
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-49760@lists.php.net to get a copy of this message
 ID:               26051
 Updated by:       sniper@php.net
 Reported By:      six at t0x dot net
-Status:           Open
+Status:           Bogus
 Bug Type:         Filesystem function related
 Operating System: win2k
 PHP Version:      4.3.4RC3
 New Comment:

PHP returns whatever the libc stat() function returns for the filetype.
No bug.



Previous Comments:
------------------------------------------------------------------------

[2003-10-31 06:06:43] six at t0x dot net

Description:
------------
As the subject states, filetype() on windows (w2k at least) returns
wrong type for device drivers. Actually, it seems to always return the
type "file".



Reproduce code:
---------------
<?

// Of course this works with any device name with any extension

echo "type : ".filetype("c:\com1.xxx");

?>

Expected result:
----------------
type : char

Actual result:
--------------
type : file


------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=26051&edit=1


Thread (7 messages)

« previous php.bugs (#49760) next »