Skip to content

Conversation

@daniloegea
Copy link
Contributor

@daniloegea daniloegea commented May 8, 2024

These problems happen when the ignore_errors flag is used.

Wifi: When parsing is interrupted before access points are added to the interface, the code that generates configuration for NM and networkd will crash. They assume the list is never empty. Add a check to see if the list is empty.

Wireguard: The same problem happens on networkd when the list of peers is empty. The NM code already checks it.

Add unit tests for these cases.

Description

Checklist

  • Runs make check successfully.
  • Retains 100% code coverage (make check-coverage).
  • New/changed keys in YAML format are documented.
  • (Optional) Adds example YAML for new feature.
  • (Optional) Closes an open bug in Launchpad.

These problems happen when the ignore_errors flag is used.

Wifi: When parsing is interrupted before access points are added to
the interface, the code that generates configuration for NM and networkd
will crash. They assume the list is never empty. Add a check to see if
the list is empty.

Wireguard: The same problem happens on networkd when the list of peers
is empty. The NM code already checks it.

Add unit tests for these cases.
@daniloegea daniloegea marked this pull request as ready for review May 9, 2024 13:26
@slyon slyon self-requested a review May 29, 2024 10:59
Copy link
Collaborator

@slyon slyon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, lgtm!

@slyon slyon merged commit 49d1ad7 into canonical:main May 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants