X-Git-Url: http://git.pk910.de/?a=blobdiff_plain;f=src%2Ftools.c;h=daedcd095ae19d28097f8814c1ef7fc362b7e433;hb=1471e99b8b975135cf4f66c0e497d4a5ded7ed77;hp=985362d17c2edf8b88835911fdbaee9088f9dc19;hpb=b3e84a339e7a4c777209b0bbceaca40bb71a2594;p=NeonServV5.git diff --git a/src/tools.c b/src/tools.c index 985362d..daedcd0 100644 --- a/src/tools.c +++ b/src/tools.c @@ -1,4 +1,4 @@ -/* tools.c - NeonServ v5.4 +/* tools.c - NeonServ v5.6 * Copyright (C) 2011-2012 Philipp Kreil (pk910) * * This program is free software: you can redistribute it and/or modify @@ -204,7 +204,7 @@ char **table_end(struct Table *table) { if(table->contents[row][col][i] == '\002') j++; else if(table->contents[row][col][i] == '\003') { j++; - for(k = 1; k < 2; k++) { + for(k = 1; k <= 2; k++) { if(isdigit(table->contents[row][col][i+k])) j++; else @@ -522,7 +522,7 @@ int isFakeHost(char *host) { char *p1, *p2 = host; //find the last dot to identify if the hostmask is a fake host - while((p1 = strstr(p2, "."))) { + while((p1 = strchr(p2, '.'))) { p2 = p1 + 1; } //TLD database: http://www.iana.org/domains/root/db/