cvs: /php4/ext/standard filestat.c info.c

From: Date: Mon, 20 Dec 1999 15:39:14 +0000
Subject: cvs: /php4/ext/standard filestat.c info.c
Groups: php.version4 
Request: Send a blank email to php-version4+get-8230@lists.php.net to get a copy of this message
zeev Mon Dec 20 10:39:14 1999 EDT Modified files: /php4/ext/standard filestat.c info.c Log: Make the Win32 tree compile again Index: php4/ext/standard/filestat.c diff -u php4/ext/standard/filestat.c:1.19 php4/ext/standard/filestat.c:1.20 --- php4/ext/standard/filestat.c:1.19 Sun Dec 19 21:09:58 1999 +++ php4/ext/standard/filestat.c Mon Dec 20 10:38:44 1999 @@ -16,7 +16,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: filestat.c,v 1.19 1999/12/20 02:09:58 evan Exp $ */ +/* $Id: filestat.c,v 1.20 1999/12/20 15:38:44 zeev Exp $ */ #include "php.h" #include "safe_mode.h" @@ -106,8 +106,8 @@ PHP_FUNCTION(diskfreespace) { + pval **path; #ifdef WINDOWS - pval *path; double bytesfree; HINSTANCE kernel32; @@ -127,7 +127,6 @@ DWORD TotalNumberOfClusters; #else /* not - WINDOWS */ - pval **path; #if defined(HAVE_SYS_STATVFS_H) && defined(HAVE_STATVFS) struct statvfs buf; #elif defined(HAVE_SYS_STATFS_H) && defined(HAVE_STATFS) @@ -154,7 +153,7 @@ /* It's available, so we can call it. */ if (gdfse) { func = (gdfse_func)gdfse; - if (func(path->value.str.val, + if (func((*path)->value.str.val, &FreeBytesAvailableToCaller, &TotalNumberOfBytes, &TotalNumberOfFreeBytes) == 0) RETURN_FALSE; @@ -166,7 +165,7 @@ } /* If it's not available, we just use GetDiskFreeSpace */ else { - if (GetDiskFreeSpace(path->value.str.val, + if (GetDiskFreeSpace((*path)->value.str.val, &SectorsPerCluster, &BytesPerSector, &NumberOfFreeClusters, &TotalNumberOfClusters) == 0) RETURN_FALSE; bytesfree = (double)NumberOfFreeClusters * (double)SectorsPerCluster * (double)BytesPerSector; @@ -180,7 +179,7 @@ #elif defined(OS2) { FSALLOCATE fsinfo; - char drive = path->value.str.val[0] & 95; + char drive = (*path)->value.str.val[0] & 95; if (DosQueryFSInfo( drive ? drive - 64 : 0, FSIL_ALLOC, &fsinfo, sizeof( fsinfo ) ) == 0) bytesfree = (double)fsinfo.cbSector * fsinfo.cSectorUnit * fsinfo.cUnitAvail; Index: php4/ext/standard/info.c diff -u php4/ext/standard/info.c:1.52 php4/ext/standard/info.c:1.53 --- php4/ext/standard/info.c:1.52 Mon Dec 20 02:12:27 1999 +++ php4/ext/standard/info.c Mon Dec 20 10:38:44 1999 @@ -100,7 +100,7 @@ #endif php_printf("php.ini path: %s<br>\n", CONFIGURATION_FILE_PATH); php_printf("ZEND_DEBUG=%d<br>\n", ZEND_DEBUG); - php_printf("SAPI=" PHP_SAPI "<br>\n"); + /*php_printf("SAPI=" PHP_SAPI "<br>\n");*/ #ifdef ZTS php_printf("ZTS is defined"); #else

« previous php.version4 (#8230) next »