File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -959,8 +959,6 @@ static php_iconv_err_t _php_iconv_mime_encode(smart_str *pretval, const char *fn
959959 goto out ;
960960 }
961961
962- buf = safe_emalloc (1 , max_line_len , 5 );
963-
964962 cd_pl = iconv_open (ICONV_ASCII_ENCODING , enc );
965963 if (cd_pl == (iconv_t )(-1 )) {
966964 if (errno == EINVAL ) {
@@ -984,6 +982,7 @@ static php_iconv_err_t _php_iconv_mime_encode(smart_str *pretval, const char *fn
984982 char_cnt = max_line_len ;
985983
986984 zend_try {
985+ buf = safe_emalloc (1 , max_line_len , 5 );
987986 _php_iconv_appendl (pretval , fname , fname_nbytes , cd_pl );
988987 char_cnt -= fname_nbytes ;
989988 smart_str_appendl (pretval , ": " , sizeof (": " ) - 1 );
@@ -1189,7 +1188,6 @@ static php_iconv_err_t _php_iconv_mime_encode(smart_str *pretval, const char *fn
11891188 } while (in_left > 0 );
11901189
11911190 smart_str_0 (pretval );
1192-
11931191 } zend_catch {
11941192 bailout = true;
11951193 } zend_end_try ();
You can’t perform that action at this time.
0 commit comments