wulijun / php-ext-trie-filter

php extension for spam word filter based on Double-Array Trie tree, it can detect if a spam word exists in a text message. 关键词过滤扩展,用于检查一段文本中是否出现敏感词,基于Double-Array Trie 树实现。
514 stars 167 forks source link

That the strlen function determines the string's length is hazardous #8

Closed agile6v closed 5 years ago

agile6v commented 7 years ago

If the input parameter is string in the zend_parse_parameters(), using strlen(STRING) may not even give the correct result, as STRING may contain one or more NULL characters prior to the end of the string.