]> git.ipfire.org Git - thirdparty/suricata-update.git/commit
Fix failure in case of missing index.yaml, cleanup
authorShivani Bhardwaj <shivanib134@gmail.com>
Mon, 25 Feb 2019 10:29:54 +0000 (15:59 +0530)
committerJason Ish <ish@unx.ca>
Thu, 17 Oct 2019 23:06:29 +0000 (17:06 -0600)
commit65df71fdf49d81d78ece24eb7ea5e165cf01a103
treea558d5617d04b955a4b7b478d041572ae909ca34
parentb7303f89a5e92da0c198bf1018343ca7b6a70696
Fix failure in case of missing index.yaml, cleanup

If the index.yaml was not present in data directory, update-sources
command would fail with an IOError. Fix this by handling this case. Now,
if sources are updated on a new data directory, there is an info message
"Adding all sources in the log".

Modularize the current structure to make it more readable and perform
one thing per function. Sort the imports and clean them.
suricata/update/commands/updatesources.py