• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
preg_match(): Compilation failed: regular expression is too large

#4
Hello, I also get this error !

I didn't have it before updrading to codeigniter3.
The workaround I found (end of post) is temporary and you don't want to leave it like that, it is a security breach.

My usecase is a BIG where_in with tousands IDs. Increasing temporarly the ini value does not work.
What should I do ?

Sincerely 
Nicolas

PHP Code:
if (strlen($conditions[$ci]) > 10000) {
//                        ini_set("pcre.backtrack_limit", 100000000000);
//                        ini_set("pcre.recursion_limit", 10000000000);
                        
continue;
                    } else {
                        if (
                            ( 
$op $this->_get_operator$conditions$ci ] ) ) === false
                            
OR ! preg_match'/^(\(?)(.*)(' preg_quote$op'/' ) . ')\s*(.*(?<!\)))?(\)?)$/i'$conditions$ci ], $matches )
                        ) {
                            continue;
                        }
                    } 
Reply


Messages In This Thread
RE: preg_match(): Compilation failed: regular expression is too large - by FnX - 08-04-2015, 03:16 AM

Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2021 MyBB Group.