Skip to content

Commit

Permalink
Worked on review comments
Browse files Browse the repository at this point in the history
Signed-off-by: DL6ER <dl6er@dl6er.de>
  • Loading branch information
DL6ER committed Dec 28, 2017
1 parent 3346a84 commit dbc9457
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 13 deletions.
12 changes: 6 additions & 6 deletions parser.c
Original file line number Diff line number Diff line change
Expand Up @@ -589,7 +589,7 @@ void process_pihole_log(int file)
if(dnsmasqID < 0)
continue;

// Save forwardID in corresponding query indentified by dnsmasq's ID
// Save status in corresponding query indentified by dnsmasq's ID
bool found = false;
for(i=0; i<counters.queries; i++)
{
Expand Down Expand Up @@ -647,7 +647,7 @@ void process_pihole_log(int file)
continue;
}

// Save forwardID in corresponding query indentified by dnsmasq's ID
// Save status and forwardID in corresponding query indentified by dnsmasq's ID
bool found = false;
for(i=0; i<counters.queries; i++)
{
Expand Down Expand Up @@ -720,7 +720,7 @@ void process_pihole_log(int file)
if(dnsmasqID < 0)
continue;

// Save forwardID in corresponding query indentified by dnsmasq's ID
// Save status in corresponding query indentified by dnsmasq's ID
bool found = false;
for(i=0; i<counters.queries; i++)
{
Expand Down Expand Up @@ -758,7 +758,7 @@ void process_pihole_log(int file)
else if(strstr(readbuffer," config ") != NULL && strstr(readbuffer," is ") != NULL)
{
// Check query for invalid characters
if(!checkQuery(readbuffer, "gravity.list"))
if(!checkQuery(readbuffer, "config"))
continue;

// Get dnsmasq's ID for this transaction
Expand All @@ -767,7 +767,7 @@ void process_pihole_log(int file)
if(dnsmasqID < 0)
continue;

// Save forwardID in corresponding query indentified by dnsmasq's ID
// Save status in corresponding query indentified by dnsmasq's ID
bool found = false;
for(i=0; i<counters.queries; i++)
{
Expand Down Expand Up @@ -832,7 +832,7 @@ void process_pihole_log(int file)
if(dnsmasqID < 0)
continue;

// Save forwardID in corresponding query indentified by dnsmasq's ID
// Save status in corresponding query indentified by dnsmasq's ID
bool found = false;
for(i=0; i<counters.queries; i++)
{
Expand Down
7 changes: 0 additions & 7 deletions request.c
Original file line number Diff line number Diff line change
Expand Up @@ -1195,13 +1195,6 @@ void getUnknownQueries(int *sock)
{
char server_message[SOCKETBUFFERLEN];

if(!debug)
{
sprintf(server_message,"For safety reasons, the command is only available in debugging mode!\n");
swrite(server_message, *sock);
return;
}

int i;
for(i=0; i < counters.queries; i++)
{
Expand Down

0 comments on commit dbc9457

Please sign in to comment.