Explorar o código

Merge pull request #173 from remicollet/issue-172

fix stack mashing using proper format
viest %!s(int64=5) %!d(string=hai) anos
pai
achega
6258018c23
Modificáronse 1 ficheiros con 2 adicións e 2 borrados
  1. 2 2
      kernel/read.c

+ 2 - 2
kernel/read.c

@@ -96,7 +96,7 @@ void data_to_custom_type(const char *string_value, zend_ulong type, zval *zv_res
 
         zend_long _long_value;
 
-        sscanf(string_value, "%" PRIi64, &_long_value);
+        sscanf(string_value, ZEND_LONG_FMT, &_long_value);
 
         if (Z_TYPE_P(zv_result_t) == IS_ARRAY) {
             add_next_index_long(zv_result_t, _long_value);
@@ -268,4 +268,4 @@ void load_sheet_all_data(xlsxioreadersheet sheet_t, zval *zv_type_t, zval *zv_re
         add_next_index_zval(zv_result_t, &_zv_tmp_row);
     }
 }
-/* }}} */
+/* }}} */