Skip to content

Commit

Permalink
Merge pull request #1278 from jjnicola/radio-type
Browse files Browse the repository at this point in the history
Fix alternative options for radio type preferences when exporting a scan config
  • Loading branch information
mattmundell authored Aug 31, 2020
2 parents 676bbf6 + caccdd2 commit 2c616d8
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 7 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
- Fix SCP alert authentication and logging [#1264](https://github.com/greenbone/gvmd/pull/1264)
- Set file mode creation mask for feed lock handling [#1265](https://github.com/greenbone/gvmd/pull/1265)
- Ignore min_qod when getting single results by UUID [#1276](http://github.com/greenbone/gvmd/pull/1276)
- Fix alternative options for radio type preferences when exporting a scan_config [#1278](http://github.com/greenbone/gvmd/pull/1278)

### Removed

Expand Down
14 changes: 7 additions & 7 deletions src/gmp.c
Original file line number Diff line number Diff line change
Expand Up @@ -8674,13 +8674,6 @@ buffer_config_preference_xml (GString *buffer, iterator_t *prefs,
char *pos = strchr (value, ';');
if (pos) *pos = '\0';
buffer_xml_append_printf (buffer, "<value>%s</value>", value);
while (pos)
{
char *pos2 = strchr (++pos, ';');
if (pos2) *pos2 = '\0';
buffer_xml_append_printf (buffer, "<alt>%s</alt>", pos);
pos = pos2;
}
}
else if (value
&& type
Expand All @@ -8698,6 +8691,13 @@ buffer_config_preference_xml (GString *buffer, iterator_t *prefs,
char *pos = strchr (default_value, ';');
if (pos) *pos = '\0';
buffer_xml_append_printf (buffer, "<default>%s</default>", default_value);
while (pos)
{
char *pos2 = strchr (++pos, ';');
if (pos2) *pos2 = '\0';
buffer_xml_append_printf (buffer, "<alt>%s</alt>", pos);
pos = pos2;
}
}
else if (default_value
&& type
Expand Down

0 comments on commit 2c616d8

Please sign in to comment.