]> granicus.if.org Git - php/commitdiff
fix printf format
authorAnatol Belski <ab@php.net>
Fri, 19 Sep 2014 08:04:12 +0000 (10:04 +0200)
committerAnatol Belski <ab@php.net>
Fri, 19 Sep 2014 08:04:12 +0000 (10:04 +0200)
main/main.c

index fde2902d64d544ae68b4df8bdaa5dec5b3adfaeb..6e6972494ae422feb8810d5909bb9feebc2d2f03 100644 (file)
@@ -1149,10 +1149,10 @@ static void php_error_cb(int type, const char *error_filename, const uint error_
                                                PG(display_errors) == PHP_DISPLAY_ERRORS_STDERR
                                        ) {
 #ifdef PHP_WIN32
-                                               fprintf(stderr, "%s: %s in %s on line %d\n", error_type_str, buffer, error_filename, error_lineno);
+                                               fprintf(stderr, "%s: %s in %s on line %u\n", error_type_str, buffer, error_filename, error_lineno);
                                                fflush(stderr);
 #else
-                                               fprintf(stderr, "%s: %s in %s on line %d\n", error_type_str, buffer, error_filename, error_lineno);
+                                               fprintf(stderr, "%s: %s in %s on line %u\n", error_type_str, buffer, error_filename, error_lineno);
 #endif
                                        } else {
                                                php_printf("%s\n%s: %s in %s on line %d\n%s", STR_PRINT(prepend_string), error_type_str, buffer, error_filename, error_lineno, STR_PRINT(append_string));
@@ -2023,7 +2023,7 @@ void dummy_invalid_parameter_handler(
                        called = 1;
                        if (function) {
                                if (file) {
-                                       len = _snprintf(buf, sizeof(buf)-1, "Invalid parameter detected in CRT function '%ws' (%ws:%d)", function, file, line);
+                                       len = _snprintf(buf, sizeof(buf)-1, "Invalid parameter detected in CRT function '%ws' (%ws:%u)", function, file, line);
                                } else {
                                        len = _snprintf(buf, sizeof(buf)-1, "Invalid parameter detected in CRT function '%ws'", function);
                                }