File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed
Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -648,7 +648,7 @@ PHP_FUNCTION(imagesetstyle)
648648 }
649649
650650 /* copy the style values in the stylearr */
651- stylearr = safe_emalloc (num_styles , sizeof (int ), 0 );
651+ stylearr = safe_emalloc (num_styles * sizeof (int ), false );
652652
653653 ZEND_HASH_FOREACH_VAL (Z_ARRVAL_P (styles ), item ) {
654654 stylearr [index ++ ] = zval_get_long (item );
@@ -3599,7 +3599,7 @@ static void php_image_filter_scatter(INTERNAL_FUNCTION_PARAMETERS)
35993599 RETURN_BOOL (gdImageScatter (im , (int )scatter_sub , (int )scatter_plus ));
36003600 }
36013601
3602- colors = emalloc (num_colors * sizeof (int ));
3602+ colors = safe_emalloc (num_colors * sizeof (int ), false );
36033603
36043604 ZEND_HASH_FOREACH_VAL (Z_ARRVAL_P (hash_colors ), color ) {
36053605 * (colors + i ++ ) = (int ) zval_get_long (color );
You can’t perform that action at this time.
0 commit comments