ID:               24482
 Updated by:       [EMAIL PROTECTED]
 Reported By:      acoon at acoon dot dk
-Status:           Open
+Status:           Analyzed
 Bug Type:         *Directory/Filesystem functions
 Operating System: FreeBSD 4.5
 PHP Version:      4.3.2
-Assigned To:      
+Assigned To:      hholzgra
 New Comment:

the comment in the manual is missleading,
GLOB_ONLYDIR is a GNU extension so it is only available on systems with
GNU libc

i'm looking into adding an emulation wrapper to the C code

if it doesn't work i'll update the documentation


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

[2003-07-03 07:30:22] acoon at acoon dot dk

Description:
------------
When using GLOB_ONLYDIR on FreeBSD 4.5 is returns an error.


PHP was configured like this.
'./configure' '--with-mysql' '--with-apxs=/usr/local/sbin/apxs'
'--with-curl' '--with-gd' '--with-jpeg-dir=/usr/local/include/'
'--with-zlib-dir' '--enable-ftp' '--with-ttf' '--enable-bcmath'


Changes made to php.ini:
register_globals = On

Reproduce code:
---------------
<?php
foreach (glob("*", GLOB_ONLYDIR) as $dir) {
    print "$dir is a dir!<BR>";
}
?>


Expected result:
----------------
I would expect to get all dirs printet.

Actual result:
--------------
Warning: glob() expects parameter 2 to be long, string given in
index.php on line 43


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


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

Reply via email to