Code cleanup

This commit is contained in:
Luca Deri
2019-12-09 15:28:44 +01:00
parent 56eeb965bf
commit 65d526d8f6
7 changed files with 32 additions and 30 deletions
+1 -1
View File
@@ -525,7 +525,7 @@ static size_t parse_slash(struct libinjection_sqli_state * sf)
* are an automatic black ban!
*/
if (memchr2(cur + 2, (size_t)(ptr - (cur + 1)), '/', '*') != NULL) {
if(ptr && (memchr2(cur + 2, (size_t)(ptr - (cur + 1)), '/', '*') != NULL)) {
ctype = TYPE_EVIL;
} else if (is_mysql_comment(cs, slen, pos)) {
ctype = TYPE_EVIL;