re.c: indent [ci skip]
* re.c (onig_new_with_source, rb_reg_search0): adjust indent. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52069 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
2b450de096
commit
907b6d32be
30
re.c
30
re.c
@ -835,24 +835,24 @@ rb_reg_named_captures(VALUE re)
|
|||||||
|
|
||||||
static int
|
static int
|
||||||
onig_new_with_source(regex_t** reg, const UChar* pattern, const UChar* pattern_end,
|
onig_new_with_source(regex_t** reg, const UChar* pattern, const UChar* pattern_end,
|
||||||
OnigOptionType option, OnigEncoding enc, const OnigSyntaxType* syntax,
|
OnigOptionType option, OnigEncoding enc, const OnigSyntaxType* syntax,
|
||||||
OnigErrorInfo* einfo, const char *sourcefile, int sourceline)
|
OnigErrorInfo* einfo, const char *sourcefile, int sourceline)
|
||||||
{
|
{
|
||||||
int r;
|
int r;
|
||||||
|
|
||||||
*reg = (regex_t* )malloc(sizeof(regex_t));
|
*reg = (regex_t* )malloc(sizeof(regex_t));
|
||||||
if (IS_NULL(*reg)) return ONIGERR_MEMORY;
|
if (IS_NULL(*reg)) return ONIGERR_MEMORY;
|
||||||
|
|
||||||
r = onig_reg_init(*reg, option, ONIGENC_CASE_FOLD_DEFAULT, enc, syntax);
|
r = onig_reg_init(*reg, option, ONIGENC_CASE_FOLD_DEFAULT, enc, syntax);
|
||||||
if (r) goto err;
|
if (r) goto err;
|
||||||
|
|
||||||
r = onig_compile(*reg, pattern, pattern_end, einfo, sourcefile, sourceline);
|
r = onig_compile(*reg, pattern, pattern_end, einfo, sourcefile, sourceline);
|
||||||
if (r) {
|
if (r) {
|
||||||
err:
|
err:
|
||||||
onig_free(*reg);
|
onig_free(*reg);
|
||||||
*reg = NULL;
|
*reg = NULL;
|
||||||
}
|
}
|
||||||
return r;
|
return r;
|
||||||
}
|
}
|
||||||
|
|
||||||
static Regexp*
|
static Regexp*
|
||||||
@ -1521,7 +1521,7 @@ rb_reg_search0(VALUE re, VALUE str, long pos, int reverse, int set_backref_str)
|
|||||||
if (err) rb_memerror();
|
if (err) rb_memerror();
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
FL_UNSET(match, FL_TAINT);
|
FL_UNSET(match, FL_TAINT);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (set_backref_str) {
|
if (set_backref_str) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user