SQLite Forum

Hidden noCase bug in ext/misc/regexp.c in pRe->zInit prefix optimization
Login
Another approach - modify lines [216-217](https://www.sqlite.org/cgi/src/file?ci=trunk&name=ext/misc/regexp.c&ln=216-217) in `re_match`.

But there are three problems:

* first char optimization `zIn[in.i]!=x` is case sensitive always. Simplest- disable this optimization in _noCase mode_
* `strcncmp` is case sensitive - we can use `sqlite3_strnicmp` in _noCase mode_
* (!) how to determine that current regexp compiled with noCase flag?