Fixed segfault in RegEx.get_capture()

This commit is contained in:
Zher Huei Lee 2015-10-20 09:48:09 +01:00
parent 6d54f82ab4
commit 26b977c967
1 changed files with 3 additions and 1 deletions

View File

@ -54,7 +54,9 @@ bool RegEx::is_valid() const {
};
int RegEx::get_capture_count() const {
ERR_FAIL_COND_V( !exp.valid(), 0 );
return exp.capture_size();
}