derick Sat Jun 28 04:21:02 2003 EDT
Modified files:
/php-src/ext/standard file.c
Log:
- Return number of bytes written instead of just TRUE. (Path by Paul Hudson,
[EMAIL PROTECTED])
Index: php-src/ext/standard/file.c
diff -u php-src/ext/standard/file.c:1.349 php-src/ext/standard/file.c:1.350
--- php-src/ext/standard/file.c:1.349 Sat Jun 14 15:30:42 2003
+++ php-src/ext/standard/file.c Sat Jun 28 04:21:02 2003
@@ -21,7 +21,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: file.c,v 1.349 2003/06/14 19:30:42 helly Exp $ */
+/* $Id: file.c,v 1.350 2003/06/28 08:21:02 derick Exp $ */
/* Synced with php 3.0 revision 1.218 1999-06-16 [ssb] */
@@ -474,8 +474,8 @@
}
/* }}} */
-/* {{{ proto string file_put_contents(string file, string data[, int flags[, resource
context]])
- Write/Create a file with contents data */
+/* {{{ proto int file_put_contents(string file, string data[, int flags[, resource
context]])
+ Write/Create a file with contents data and returns the number */
PHP_FUNCTION(file_put_contents)
{
php_stream *stream;
@@ -506,7 +506,7 @@
}
php_stream_close(stream);
- RETURN_TRUE;
+ RETURN_LONG(numbytes);
}
/* }}} */
--
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php