Closed jvm3487 closed 6 years ago
Hi @ManofWax and @adepasquale ,
Not to rush, but I wasn't sure if you saw this since it was opened it at the same time as my bugfix PR (https://github.com/certego/fw1-loggrabber/pull/47). I was hoping to get your thoughts on this, and thank you for your consideration.
Hi @jvm3487, we think that your idea is fine.
However there should be a clear error/warning message when --loc
is negative number, at least to inform users that if that parameter is not a positive integer it will be considered as 0
.
Also I will prefer avoid using atoi
with "untrusted" (aka: cli provided) input, cause its behaviour is undefined when input is not a string which represents an integer (see this SO thread, this article and this post on Mozilla blog ).
@sevdog Thank you very much for your feedback! I have made changes based off your suggestions and added them to the PR. Please let me know if you have any other suggestions.
Thanks @sevdog !
We have a requirement to be able to explicitly specify a starting record number from the command line when working with an ng firewall in offline mode similar to the below PR. I was wondering if a change similar to this would also be acceptable to the main fw1-loggrabber repository.
@adepasquale please let me know your thoughts if you get a chance, and thank you for your time.