diff options
author | Russ Allbery <eagle@eyrie.org> | 2018-03-31 19:07:17 -0700 |
---|---|---|
committer | Russ Allbery <eagle@eyrie.org> | 2018-04-01 16:14:31 -0700 |
commit | cb6b132904141b560f553df0e03287945dad1352 (patch) | |
tree | 13fb170c2295301c9cf852f945a01382310d16dc /php | |
parent | 62e412902ea3c8cd5a7d2c1349c4e073903c7f74 (diff) |
Add a check-cppcheck target and fix what it found
Add maintainer check-cppcheck target to run cppcheck across the source
base with a standard configuration. Fix all issues found by cppcheck.
Diffstat (limited to 'php')
-rw-r--r-- | php/php_remctl.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/php/php_remctl.c b/php/php_remctl.c index 570ac13..7ef073e 100644 --- a/php/php_remctl.c +++ b/php/php_remctl.c @@ -5,9 +5,9 @@ * the Net::Remctl bindings for Perl. * * Originally written by Andrew Mortensen <admorten@umich.edu>, 2008 - * Copyirght 2016 Russ Allbery <eagle@eyrie.org> + * Copyright 2016, 2018 Russ Allbery <eagle@eyrie.org> * Copyright 2008 Andrew Mortensen <admorten@umich.edu> - * Copyright 2008, 2011, 2012, 2014 + * Copyright 2008, 2011-2012, 2014 * The Board of Trustees of the Leland Stanford Junior University * * See LICENSE for licensing terms. @@ -94,7 +94,8 @@ PHP_MINIT_FUNCTION(remctl) */ ZEND_FUNCTION(remctl) { - zval *cmd_array, *data; + zval *cmd_array; + zval *data = NULL; HashTable *hash; char *host, *principal = NULL; const char **command = NULL; @@ -329,7 +330,8 @@ ZEND_FUNCTION(remctl_open) ZEND_FUNCTION(remctl_command) { struct remctl *r; - zval *zrem, *cmd_array, *data; + zval *zrem, *cmd_array; + zval *data = NULL; HashTable *hash; struct iovec *cmd_vec = NULL; int i, count, status; |