Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Initialize struct #438

Merged
merged 3 commits into from
Feb 8, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
### Added
### Changed
### Fixed
* Adding initialization to struct scanner in `boreas/util_tests.c`. [#438](https://github.com/greenbone/gvm-libs/pull/438)

### Removed

[20.8.2]: https://github.com/greenbone/gvm-libs/compare/v20.8.1...gvm-libs-20.08
Expand Down
4 changes: 2 additions & 2 deletions base/networking.c
Original file line number Diff line number Diff line change
Expand Up @@ -651,7 +651,7 @@ port_range_ranges (const char *port_range)

if (element_strlen >= 2)
{
if ((element[0] == 'T'))
if (element[0] == 'T')
{
element++;
while (*element && isblank (*element))
Expand All @@ -662,7 +662,7 @@ port_range_ranges (const char *port_range)
tcp = 1;
}
}
else if ((element[0] == 'U'))
else if (element[0] == 'U')
{
element++;
while (*element && isblank (*element))
Expand Down
2 changes: 1 addition & 1 deletion boreas/util_tests.c
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ Ensure (util, set_all_needed_sockets)
g_setsockopt_use_real = false;

alive_test_t alive_test;
struct scanner scanner = {};
struct scanner scanner = {0};

/* All methods set. */
alive_test = ALIVE_TEST_TCP_ACK_SERVICE | ALIVE_TEST_ICMP | ALIVE_TEST_ARP
Expand Down