cvs: php-src(PHP_4_3) /ext/standard assert.c fsock.c math.c scanf.c var.c

From: Date: Thu, 28 Aug 2003 16:01:50 +0000
Subject: cvs: php-src(PHP_4_3) /ext/standard assert.c fsock.c math.c scanf.c var.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-23443@lists.php.net to get a copy of this message
sas Thu Aug 28 12:01:50 2003 EDT Modified files: (Branch: PHP_4_3) /php-src/ext/standard assert.c fsock.c math.c scanf.c var.c Log: fix format strings Index: php-src/ext/standard/assert.c diff -u php-src/ext/standard/assert.c:1.50.2.2 php-src/ext/standard/assert.c:1.50.2.3 --- php-src/ext/standard/assert.c:1.50.2.2 Wed Aug 13 20:38:21 2003 +++ php-src/ext/standard/assert.c Thu Aug 28 12:01:49 2003 @@ -16,7 +16,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: assert.c,v 1.50.2.2 2003/08/14 00:38:21 iliaa Exp $ */ +/* $Id: assert.c,v 1.50.2.3 2003/08/28 16:01:49 sas Exp $ */ /* {{{ includes/startup/misc */ @@ -280,7 +280,7 @@ break; default: - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unknown value %d", Z_LVAL_PP(what)); + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unknown value %ld", Z_LVAL_PP(what)); break; } Index: php-src/ext/standard/fsock.c diff -u php-src/ext/standard/fsock.c:1.106.2.9 php-src/ext/standard/fsock.c:1.106.2.10 --- php-src/ext/standard/fsock.c:1.106.2.9 Thu Aug 28 11:15:35 2003 +++ php-src/ext/standard/fsock.c Thu Aug 28 12:01:49 2003 @@ -18,7 +18,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: fsock.c,v 1.106.2.9 2003/08/28 15:15:35 sas Exp $ */ +/* $Id: fsock.c,v 1.106.2.10 2003/08/28 16:01:49 sas Exp $ */ /* converted to PHP Streams and moved much code to main/network.c [wez] */ @@ -229,7 +229,7 @@ err = php_socket_errno(); if (stream == NULL) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "unable to connect to %s:%d", host, port); + php_error_docref(NULL TSRMLS_CC, E_WARNING, "unable to connect to %s:%ld", host, port); } else if (context) { php_stream_context_set(stream, context); } Index: php-src/ext/standard/math.c diff -u php-src/ext/standard/math.c:1.97.2.6 php-src/ext/standard/math.c:1.97.2.7 --- php-src/ext/standard/math.c:1.97.2.6 Sat Aug 9 12:13:47 2003 +++ php-src/ext/standard/math.c Thu Aug 28 12:01:49 2003 @@ -19,7 +19,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: math.c,v 1.97.2.6 2003/08/09 16:13:47 iliaa Exp $ */ +/* $Id: math.c,v 1.97.2.7 2003/08/28 16:01:49 sas Exp $ */ #include "php.h" #include "php_math.h" @@ -968,11 +968,11 @@ convert_to_long_ex(frombase); convert_to_long_ex(tobase); if (Z_LVAL_PP(frombase) < 2 || Z_LVAL_PP(frombase) > 36) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid `from base' (%d)", Z_LVAL_PP(frombase)); + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid `from base' (%ld)", Z_LVAL_PP(frombase)); RETURN_FALSE; } if (Z_LVAL_PP(tobase) < 2 || Z_LVAL_PP(tobase) > 36) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid `to base' (%d)", Z_LVAL_PP(tobase)); + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid `to base' (%ld)", Z_LVAL_PP(tobase)); RETURN_FALSE; } Index: php-src/ext/standard/scanf.c diff -u php-src/ext/standard/scanf.c:1.16.4.5 php-src/ext/standard/scanf.c:1.16.4.6 --- php-src/ext/standard/scanf.c:1.16.4.5 Tue Apr 22 22:37:29 2003 +++ php-src/ext/standard/scanf.c Thu Aug 28 12:01:49 2003 @@ -16,7 +16,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: scanf.c,v 1.16.4.5 2003/04/23 02:37:29 iliaa Exp $ */ +/* $Id: scanf.c,v 1.16.4.6 2003/08/28 16:01:49 sas Exp $ */ /* scanf.c -- @@ -408,7 +408,7 @@ gotSequential = 1; if (gotXpg) { mixedXPG: - php_error_docref(NULL TSRMLS_CC, E_WARNING, "cannot mix \"%\" and \"%n$\" conversion specifiers"); + php_error_docref(NULL TSRMLS_CC, E_WARNING, "%s", "cannot mix \"%\" and \"%n$\" conversion specifiers"); goto error; } @@ -495,7 +495,7 @@ goto error; default: { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Bad scan conversion character \"%c\"", ch); + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Bad scan conversion character \"%c\"", *ch); goto error; } } @@ -545,7 +545,7 @@ } for (i = 0; i < numVars; i++) { if (nassign[i] > 1) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "Variable is assigned by multiple \"%n$\" conversion specifiers"); + php_error_docref(NULL TSRMLS_CC, E_WARNING, "%s", "Variable is assigned by multiple \"%n$\" conversion specifiers"); goto error; } else if (!xpgSize && (nassign[i] == 0)) { /* @@ -564,7 +564,7 @@ badIndex: if (gotXpg) { - php_error_docref(NULL TSRMLS_CC, E_WARNING, "\"%n$\" argument index out of range"); + php_error_docref(NULL TSRMLS_CC, E_WARNING, "%s", "\"%n$\" argument index out of range"); } else { php_error_docref(NULL TSRMLS_CC, E_WARNING, "Different numbers of variable names and field specifiers"); } Index: php-src/ext/standard/var.c diff -u php-src/ext/standard/var.c:1.150.2.9 php-src/ext/standard/var.c:1.150.2.10 --- php-src/ext/standard/var.c:1.150.2.9 Mon Aug 11 00:57:55 2003 +++ php-src/ext/standard/var.c Thu Aug 28 12:01:49 2003 @@ -514,7 +514,7 @@ char *s; ulong slen; - slen = spprintf(&s, 0, "d:%.*G;", PG(serialize_precision), Z_DVAL_PP(struc)); + slen = spprintf(&s, 0, "d:%.*G;", (int) PG(serialize_precision), Z_DVAL_PP(struc)); smart_str_appendl(buf, s, slen); efree(s); return;

« previous php.cvs (#23443) next »