Skip to content

Commit

Permalink
Fix: warning detected via ccc-analyzer
Browse files Browse the repository at this point in the history
Bug Summary
File:	src/openvas.c
Warning:	line 609, column 12
Although the value stored to 'err' is used in the enclosing expression, the value is never actually read from 'err'
  • Loading branch information
jjnicola committed Oct 21, 2022
1 parent 36bb752 commit 4c7a664
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/openvas.c
Original file line number Diff line number Diff line change
Expand Up @@ -606,8 +606,9 @@ openvas (int argc, char *argv[], char *env[])
set_scan_id (g_strdup (scan_id));
globals = g_malloc0 (sizeof (struct scan_globals));
globals->scan_id = g_strdup (get_scan_id ());

if ((err = attack_network_init (globals, config_file)) != 0)

err = attack_network_init (globals, config_file);
if (err != 0)
return EXIT_FAILURE;

attack_network (globals);
Expand Down

0 comments on commit 4c7a664

Please sign in to comment.