From: Rasmus Lerdorf Date: Mon, 16 May 2011 15:52:31 +0000 (+0000) Subject: Fix a couple of warnings. Use %zu to printf a time_t and get_request_time X-Git-Tag: php-5.5.0alpha1~2093 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=e0df4e3dba7c4ab92442b9e82c1de01fdbaa3cce;p=php Fix a couple of warnings. Use %zu to printf a time_t and get_request_time actually returns a double, not a time_t. --- diff --git a/main/SAPI.h b/main/SAPI.h index 3966b2d5aa..aca4179430 100644 --- a/main/SAPI.h +++ b/main/SAPI.h @@ -241,7 +241,7 @@ struct _sapi_module_struct { void (*register_server_variables)(zval *track_vars_array TSRMLS_DC); void (*log_message)(char *message TSRMLS_DC); - time_t (*get_request_time)(TSRMLS_D); + double (*get_request_time)(TSRMLS_D); void (*terminate_process)(TSRMLS_D); char *php_ini_path_override; diff --git a/sapi/apache2handler/sapi_apache2.c b/sapi/apache2handler/sapi_apache2.c index 0d1cad0630..48eea2b6fb 100644 --- a/sapi/apache2handler/sapi_apache2.c +++ b/sapi/apache2handler/sapi_apache2.c @@ -670,7 +670,7 @@ zend_first_try { } apr_table_set(r->notes, "mod_php_memory_usage", - apr_psprintf(ctx->r->pool, "%u", zend_memory_peak_usage(1 TSRMLS_CC))); + apr_psprintf(ctx->r->pool, "%zu", zend_memory_peak_usage(1 TSRMLS_CC))); } } zend_end_try();