mirror of
git://erdgeist.org/opentracker
synced 2025-02-05 03:26:25 +00:00
Lot of Gehacktes around this keyword scanner. Don't return a match if string to compare is shorter than key from table.
This commit is contained in:
parent
de5dbad258
commit
1d821b95cb
@ -75,7 +75,7 @@ int scan_find_keywords( const ot_keywords * keywords, char **string, SCAN_SEARCH
|
|||||||
if( match_length == 0 ) return -3;
|
if( match_length == 0 ) return -3;
|
||||||
|
|
||||||
while( keywords->key ) {
|
while( keywords->key ) {
|
||||||
if( !strncmp( keywords->key, deststring, match_length ) )
|
if( !strncmp( keywords->key, deststring, match_length ) && !keywords->key[match_length] )
|
||||||
return keywords->value;
|
return keywords->value;
|
||||||
keywords++;
|
keywords++;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user