]> granicus.if.org Git - php/commitdiff
Reduce (some more) compile noise of 'unused variable' and 'may be used
authorChristopher Jones <sixd@php.net>
Tue, 20 Aug 2013 00:17:54 +0000 (17:17 -0700)
committerChristopher Jones <sixd@php.net>
Tue, 20 Aug 2013 00:17:54 +0000 (17:17 -0700)
uninitialized' warnings.

ext/curl/interface.c
ext/intl/calendar/calendar_methods.cpp
ext/intl/calendar/gregoriancalendar_methods.cpp
ext/intl/msgformat/msgformat_helpers.cpp

index 861795485d1c02163ec2276c566ac60c56227695..9fdb57cc4e68f0053b02aa3feb534b660674d8fd 100644 (file)
@@ -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";
index db10502a1837f17d94b5ae046a6f596995a961cf..ae7d0093f784ea31d06136d566d4dbb971c85fa8 100644 (file)
@@ -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) {
index 3c05253de1e195852ba890ec255fc9ff00621819..08b894964c992acc512b20aa1c0a1ed06dbba0c8 100644 (file)
@@ -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)
index 9ee1cdcfb0d174f72ddcffc5206c079d986f1e4a..c4456d54f3c84b78e4bafe8acbabeda3ad9e7b54 100644 (file)
@@ -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 ||