Skip to content

Commit

Permalink
Add an error message to the if statement if it fails.
Browse files Browse the repository at this point in the history
  • Loading branch information
nickchappell committed Jun 11, 2016
1 parent 908ff28 commit a611a68
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion sandbox/lua/decoders/bind_query_log.lua
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,8 @@ function process_message ()
fields = grammar:match(query_log_line)

--If fields is empty, exit immediately:
if not fields then return -1 end
if not ok then return -1, "Failed to parse the BIND query log line." end

--Set the time in the message we're generating and set it to nil in the original log line:
msg.Timestamp = fields.time
fields.time = nil
Expand Down

0 comments on commit a611a68

Please sign in to comment.