@@ -868,7 +868,7 @@ init_dfa (re_dfa_t *dfa, size_t pat_len)
868
868
if (table_size > pat_len )
869
869
break ;
870
870
871
- dfa -> state_table = calloc (sizeof (struct re_state_table_entry ), table_size );
871
+ dfa -> state_table = calloc (table_size , sizeof (struct re_state_table_entry ));
872
872
dfa -> state_hash_mask = table_size - 1 ;
873
873
874
874
dfa -> mb_cur_max = MB_CUR_MAX ;
@@ -936,7 +936,7 @@ init_dfa (re_dfa_t *dfa, size_t pat_len)
936
936
{
937
937
int i , j , ch ;
938
938
939
- dfa -> sb_char = (re_bitset_ptr_t ) calloc (sizeof (bitset_t ), 1 );
939
+ dfa -> sb_char = (re_bitset_ptr_t ) calloc (1 , sizeof (bitset_t ));
940
940
if (BE (dfa -> sb_char == NULL , 0 ))
941
941
return REG_ESPACE ;
942
942
@@ -3079,9 +3079,9 @@ parse_bracket_exp (re_string_t *regexp, re_dfa_t *dfa, re_token_t *token,
3079
3079
_NL_COLLATE_SYMB_EXTRAMB );
3080
3080
}
3081
3081
#endif
3082
- sbcset = (re_bitset_ptr_t ) calloc (sizeof (bitset_t ), 1 );
3082
+ sbcset = (re_bitset_ptr_t ) calloc (1 , sizeof (bitset_t ));
3083
3083
#ifdef RE_ENABLE_I18N
3084
- mbcset = (re_charset_t * ) calloc (sizeof (re_charset_t ), 1 );
3084
+ mbcset = (re_charset_t * ) calloc (1 , sizeof (re_charset_t ));
3085
3085
#endif /* RE_ENABLE_I18N */
3086
3086
#ifdef RE_ENABLE_I18N
3087
3087
if (BE (sbcset == NULL || mbcset == NULL , 0 ))
@@ -3626,9 +3626,9 @@ build_charclass_op (re_dfa_t *dfa, RE_TRANSLATE_TYPE trans,
3626
3626
re_token_t br_token ;
3627
3627
bin_tree_t * tree ;
3628
3628
3629
- sbcset = (re_bitset_ptr_t ) calloc (sizeof (bitset_t ), 1 );
3629
+ sbcset = (re_bitset_ptr_t ) calloc (1 , sizeof (bitset_t ));
3630
3630
#ifdef RE_ENABLE_I18N
3631
- mbcset = (re_charset_t * ) calloc (sizeof (re_charset_t ), 1 );
3631
+ mbcset = (re_charset_t * ) calloc (1 , sizeof (re_charset_t ));
3632
3632
#endif /* RE_ENABLE_I18N */
3633
3633
3634
3634
#ifdef RE_ENABLE_I18N
0 commit comments