cvs: php-src /ext/sysvmsg sysvmsg.c
| From: | Antony Dovgal | Date: | Sun, 18 Dec 2005 12:48:22 +0000 |
| Subject: | cvs: php-src /ext/sysvmsg sysvmsg.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-36008@lists.php.net to get a copy of this message | ||
tony2001 Sun Dec 18 12:48:22 2005 EDT
Modified files:
/php-src/ext/sysvmsg sysvmsg.c
Log:
fix possible usage of uninitialized variable
http://cvs.php.net/viewcvs.cgi/php-src/ext/sysvmsg/sysvmsg.c?r1=1.21&r2=1.22&diff_format=u
Index: php-src/ext/sysvmsg/sysvmsg.c
diff -u php-src/ext/sysvmsg/sysvmsg.c:1.21 php-src/ext/sysvmsg/sysvmsg.c:1.22
--- php-src/ext/sysvmsg/sysvmsg.c:1.21 Tue Dec 6 02:24:50 2005
+++ php-src/ext/sysvmsg/sysvmsg.c Sun Dec 18 12:48:22 2005
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: sysvmsg.c,v 1.21 2005/12/06 02:24:50 sniper Exp $ */
+/* $Id: sysvmsg.c,v 1.22 2005/12/18 12:48:22 tony2001 Exp $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
@@ -142,7 +142,7 @@
{
php_info_print_table_start();
php_info_print_table_row(2, "sysvmsg support", "enabled");
- php_info_print_table_row(2, "Revision", "$Revision: 1.21 $");
+ php_info_print_table_row(2, "Revision", "$Revision: 1.22 $");
php_info_print_table_end();
}
/* }}} */
@@ -341,8 +341,9 @@
if (!php_var_unserialize(&tmp, &p, p + result, &var_hash TSRMLS_CC)) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "message corrupted");
RETVAL_FALSE;
+ } else {
+ REPLACE_ZVAL_VALUE(&out_message, tmp, 1);
}
- REPLACE_ZVAL_VALUE(&out_message, tmp, 0);
FREE_ZVAL(tmp);
PHP_VAR_UNSERIALIZE_DESTROY(var_hash);
} else {