com php-src: - add reminder for checking return values: sapi/cli/php_cli_server.c
| From: | Pierre Joye | Date: | Sun, 24 Mar 2013 12:27:00 +0000 |
| Subject: | com php-src: - add reminder for checking return values: sapi/cli/php_cli_server.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-71710@lists.php.net to get a copy of this message | ||
Commit: bb18fa448c104c10d0899090bf64ca66e36e492e
Author: Pierre Joye <pierre.php@gmail.com> Sun, 24 Mar 2013 13:27:00 +0100
Parents: 3af489683753ab31d7397812989e82f6a424d244
Branches: master
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=bb18fa448c104c10d0899090bf64ca66e36e492e
Log:
- add reminder for checking return values
Changed paths:
M sapi/cli/php_cli_server.c
Diff:
diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c
index e834e75..903f042 100644
--- a/sapi/cli/php_cli_server.c
+++ b/sapi/cli/php_cli_server.c
@@ -315,6 +315,8 @@ int php_cli_server_get_system_time(char *buf) {
struct tm tm;
gettimeofday(&tv, NULL);
+
+ /* TODO: should be checked for NULL tm/return vaue */
php_localtime_r(&tv.tv_sec, &tm);
php_asctime_r(&tm, buf);
return 0;