diff --git a/ext/bz2/bz2_filter.c b/ext/bz2/bz2_filter.c index 5ed7921c17d..335600232b3 100644 --- a/ext/bz2/bz2_filter.c +++ b/ext/bz2/bz2_filter.c @@ -215,7 +215,6 @@ static php_stream_filter_status_t php_bz2_compress_filter( size_t consumed = 0; int status; php_stream_filter_status_t exit_status = PSFS_FEED_ME; - bz_stream *streamp; if (!thisfilter || !thisfilter->abstract) { /* Should never happen */ @@ -223,7 +222,6 @@ static php_stream_filter_status_t php_bz2_compress_filter( } data = (php_bz2_filter_data *)(thisfilter->abstract); - streamp = &(data->strm); while (buckets_in->head) { size_t bin = 0, desired; diff --git a/ext/curl/interface.c b/ext/curl/interface.c index a1c8a1e520c..ac872dfbc2c 100644 --- a/ext/curl/interface.c +++ b/ext/curl/interface.c @@ -2441,7 +2441,7 @@ string_copy: ph = HASH_OF(*zvalue); if (!ph) { - char *name; + char *name = NULL; switch (option) { case CURLOPT_HTTPHEADER: name = "CURLOPT_HTTPHEADER"; diff --git a/ext/ftp/ftp.c b/ext/ftp/ftp.c index 0d6704f9d21..2c5bc5d7e39 100644 --- a/ext/ftp/ftp.c +++ b/ext/ftp/ftp.c @@ -790,7 +790,6 @@ int ftp_get(ftpbuf_t *ftp, php_stream *outstream, const char *path, ftptype_t type, long resumepos TSRMLS_DC) { databuf_t *data = NULL; - int lastch; size_t rcvd; char arg[11]; @@ -828,7 +827,6 @@ ftp_get(ftpbuf_t *ftp, php_stream *outstream, const char *path, ftptype_t type, goto bail; } - lastch = 0; while ((rcvd = my_recv(ftp, data->fd, data->buf, FTP_BUFSIZE))) { if (rcvd == -1) { goto bail; @@ -1187,12 +1185,9 @@ ftp_readline(ftpbuf_t *ftp) int ftp_getresp(ftpbuf_t *ftp) { - char *buf; - if (ftp == NULL) { return 0; } - buf = ftp->inbuf; ftp->resp = 0; while (1) { diff --git a/ext/intl/calendar/calendar_methods.cpp b/ext/intl/calendar/calendar_methods.cpp index db10502a183..ae7d0093f78 100644 --- a/ext/intl/calendar/calendar_methods.cpp +++ b/ext/intl/calendar/calendar_methods.cpp @@ -184,7 +184,6 @@ U_CFUNC PHP_FUNCTION(intlcal_get_keyword_values_for_locale) U_CFUNC PHP_FUNCTION(intlcal_get_now) { - UErrorCode status = U_ZERO_ERROR; intl_error_reset(NULL TSRMLS_CC); if (zend_parse_parameters_none() == FAILURE) { diff --git a/ext/intl/calendar/gregoriancalendar_methods.cpp b/ext/intl/calendar/gregoriancalendar_methods.cpp index 3c05253de1e..08b894964c9 100644 --- a/ext/intl/calendar/gregoriancalendar_methods.cpp +++ b/ext/intl/calendar/gregoriancalendar_methods.cpp @@ -38,7 +38,6 @@ static inline GregorianCalendar *fetch_greg(Calendar_object *co) { static void _php_intlgregcal_constructor_body(INTERNAL_FUNCTION_PARAMETERS) { - zval *object = getThis(); zval **tz_object = NULL; zval **args_a[6] = {0}, ***args = &args_a[0]; @@ -84,7 +83,7 @@ static void _php_intlgregcal_constructor_body(INTERNAL_FUNCTION_PARAMETERS) } // instantion of ICU object - GregorianCalendar *gcal; + GregorianCalendar *gcal = NULL; if (variant <= 2) { // From timezone and locale (0 to 2 arguments) diff --git a/ext/intl/msgformat/msgformat_helpers.cpp b/ext/intl/msgformat/msgformat_helpers.cpp index 9ee1cdcfb0d..c4456d54f3c 100644 --- a/ext/intl/msgformat/msgformat_helpers.cpp +++ b/ext/intl/msgformat/msgformat_helpers.cpp @@ -487,7 +487,7 @@ U_CFUNC void umsg_format_helper(MessageFormatter_object *mfo, } case Formattable::kLong: { - int32_t tInt32; + int32_t tInt32 = 0; retry_klong: if (Z_TYPE_PP(elem) == IS_DOUBLE) { if (Z_DVAL_PP(elem) > (double)INT32_MAX || @@ -517,7 +517,7 @@ retry_klong: } case Formattable::kInt64: { - int64_t tInt64; + int64_t tInt64 = 0; retry_kint64: if (Z_TYPE_PP(elem) == IS_DOUBLE) { if (Z_DVAL_PP(elem) > (double)U_INT64_MAX || diff --git a/ext/intl/resourcebundle/resourcebundle_class.c b/ext/intl/resourcebundle/resourcebundle_class.c index 9c369bdecc4..dc1212431a9 100644 --- a/ext/intl/resourcebundle/resourcebundle_class.c +++ b/ext/intl/resourcebundle/resourcebundle_class.c @@ -163,7 +163,6 @@ static void resourcebundle_array_fetch(zval *object, zval *offset, zval *return_ { int32_t meindex = 0; char * mekey = NULL; - long mekeylen; zend_bool is_numeric = 0; char *pbuf; ResourceBundle_object *rb; @@ -177,7 +176,6 @@ static void resourcebundle_array_fetch(zval *object, zval *offset, zval *return_ rb->child = ures_getByIndex( rb->me, meindex, rb->child, &INTL_DATA_ERROR_CODE(rb) ); } else if(Z_TYPE_P(offset) == IS_STRING) { mekey = Z_STRVAL_P(offset); - mekeylen = Z_STRLEN_P(offset); rb->child = ures_getByKey(rb->me, mekey, rb->child, &INTL_DATA_ERROR_CODE(rb) ); } else { intl_errors_set(INTL_DATA_ERROR_P(rb), U_ILLEGAL_ARGUMENT_ERROR, diff --git a/ext/openssl/openssl.c b/ext/openssl/openssl.c index 578f738da99..4aac4e3137c 100644 --- a/ext/openssl/openssl.c +++ b/ext/openssl/openssl.c @@ -600,7 +600,7 @@ static void add_assoc_name_entry(zval * val, char * key, X509_NAME * name, int s { zval **data; zval *subitem, *subentries; - int i, j = -1, last = -1, obj_cnt = 0; + int i; char *sname; int nid; X509_NAME_ENTRY * ne; @@ -622,7 +622,6 @@ static void add_assoc_name_entry(zval * val, char * key, X509_NAME * name, int s ne = X509_NAME_get_entry(name, i); obj = X509_NAME_ENTRY_get_object(ne); nid = OBJ_obj2nid(obj); - obj_cnt = 0; if (shortname) { sname = (char *) OBJ_nid2sn(nid);