X-Git-Url: http://ftp.carnet.hr/carnet-debian/scm?a=blobdiff_plain;f=src%2Fos_regex%2Fos_regex_str.c;h=2bc22122a107d36b3b6e36a2f7c1edfd49a9eef8;hb=372b53a05f545963ee37488149828312a47b3171;hp=13b46cacd87fd3a5b80ff7a78c6b1c3ee5e3d042;hpb=914feba5d54f979cd5d7e69c349c3d01f630042a;p=ossec-hids.git diff --git a/src/os_regex/os_regex_str.c b/src/os_regex/os_regex_str.c index 13b46ca..2bc2212 100755 --- a/src/os_regex/os_regex_str.c +++ b/src/os_regex/os_regex_str.c @@ -5,7 +5,7 @@ * * This program is a free software; you can redistribute it * and/or modify it under the terms of the GNU General Public - * License (version 3) as published by the FSF - Free Software + * License (version 2) as published by the FSF - Free Software * Foundation */ @@ -23,12 +23,12 @@ int OS_StrIsNum(char *str) { if(str == NULL) return(FALSE); - + while(*str != '\0') { if(!_IsD(*str)) return(FALSE); /* 0 */ - str++; + str++; } return(TRUE); @@ -37,12 +37,12 @@ int OS_StrIsNum(char *str) /** int OS_StrHowClosedMatch(char *str1, char *str2) v0.1 * Returns the number of characters that both strings - * have in similar. + * have in similar. */ int OS_StrHowClosedMatch(char *str1, char *str2) { int count = 0; - + /* They don't match if any of them is null */ if(!str1 || !str2) { @@ -58,7 +58,7 @@ int OS_StrHowClosedMatch(char *str1, char *str2) count++; }while((str1[count] != '\0') && (str2[count] != '\0')); - + return(count); } @@ -68,7 +68,7 @@ int OS_StrHowClosedMatch(char *str1, char *str2) * Verifies if a string starts with the provided pattern. * Returns 1 on success or 0 on failure. */ -#define startswith(x,y) (strncmp(x,y,strlen(y)) == 0?1:0) -#define OS_StrStartsWith startswith +#define startswith(x,y) (strncmp(x,y,strlen(y)) == 0?1:0) +#define OS_StrStartsWith startswith /* EOF */