slre icon indicating copy to clipboard operation
slre copied to clipboard

memory out of range

Open legier opened this issue 8 years ago • 1 comments

I want to use slre in my embedded project, but when I use it I am falling into HardFalt interrupt because of memory corruption. I can't show any places, but when I comment all calls to slre_match method. everything is fine.

This is my example: slre_cap CapturedExp[20]; (slre_match("([ ]*\r)", "diag\r", 5, CapturedExp, 10, SLRE_IGNORE_CASE)

legier avatar Jan 17 '17 22:01 legier

Is one of this regex incorrect or not supported: char* CModuleCommands::pCommands[] = { (char*) "^[ ](18|reset )", (char) "^[ ](0|on )", (char) "^[ ](1|off )", (char) "^[ ](2|(b(lank)? ))", (char) "^[ ](3|(r(efresh)? ))", (char) "^[ ]*(4|config)",

(char*) "^[ ](10|dc)", (char) "^[ ](11|(l(ightness)? ))", (char) "^[ ](12|(g(amma)? ))", (char) "^[ ](13|(p(ixel|x)? ))", (char) "^[ ]*(14|(m(emory)? ))",

(char*) "^[ ]*(20|(a(nimation)? )",

(char*) "^[ ](30|diag)", (char) "^[ ]*(31|rng)", };

because my problem is really annoying.

legier avatar Feb 09 '17 23:02 legier