sas Tue Feb 20 23:18:30 2001 EDT Modified files: /php4/ext/standard file.c filestat.c Log: Correctly check for the existence of the st_rdev field. Note that this field is required to exist for SUSv3 conformance. Submitted by: [EMAIL PROTECTED] PR: #9358 Index: php4/ext/standard/file.c diff -u php4/ext/standard/file.c:1.141 php4/ext/standard/file.c:1.142 --- php4/ext/standard/file.c:1.141 Fri Feb 16 05:13:52 2001 +++ php4/ext/standard/file.c Tue Feb 20 23:18:28 2001 @@ -20,7 +20,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: file.c,v 1.141 2001/02/16 13:13:52 eschmid Exp $ */ +/* $Id: file.c,v 1.142 2001/02/21 07:18:28 sas Exp $ */ /* Synced with php 3.0 revision 1.218 1999-06-16 [ssb] */ @@ -1624,8 +1624,10 @@ add_assoc_long ( return_value , "uid" , stat_sb.st_uid ); add_assoc_long ( return_value , "gid" , stat_sb.st_gid ); -#ifdef HAVE_ST_BLKSIZE +#ifdef HAVE_ST_RDEV add_assoc_long ( return_value, "rdev" , stat_sb.st_rdev ); +#endif +#ifdef HAVE_ST_BLKSIZE add_assoc_long ( return_value , "blksize" , stat_sb.st_blksize ); #endif Index: php4/ext/standard/filestat.c diff -u php4/ext/standard/filestat.c:1.53 php4/ext/standard/filestat.c:1.54 --- php4/ext/standard/filestat.c:1.53 Thu Feb 15 12:33:09 2001 +++ php4/ext/standard/filestat.c Tue Feb 20 23:18:28 2001 @@ -16,7 +16,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: filestat.c,v 1.53 2001/02/15 20:33:09 eschmid Exp $ */ +/* $Id: filestat.c,v 1.54 2001/02/21 07:18:28 sas Exp $ */ #include "php.h" #include "safe_mode.h" @@ -593,7 +593,7 @@ add_next_index_long(return_value, stat_sb->st_nlink); add_next_index_long(return_value, stat_sb->st_uid); add_next_index_long(return_value, stat_sb->st_gid); -#ifdef HAVE_ST_BLKSIZE +#ifdef HAVE_ST_RDEV add_next_index_long(return_value, stat_sb->st_rdev); #else add_next_index_long(return_value, -1); -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]