Skip to content

nm: return if write_routes() fails#345

Merged
slyon merged 1 commit intocanonical:mainfrom
daniloegea:fix_critical_assert_write_nm_conf
Apr 24, 2023
Merged

nm: return if write_routes() fails#345
slyon merged 1 commit intocanonical:mainfrom
daniloegea:fix_critical_assert_write_nm_conf

Conversation

@daniloegea
Copy link
Contributor

@daniloegea daniloegea commented Apr 21, 2023

When routes validation fails we should return. It's also hitting an assertion later because the "error" object is already built:

(generate:246468): GLib-CRITICAL **: 09:45:27.526: g_key_file_save_to_file: assertion 'error == NULL || *error == NULL' failed

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.

When routes validation fails we should return. It's also hitting an
assertion later because the "error" object is already built:

g_key_file_save_to_file: assertion 'error == NULL || *error == NULL' failed

Add a test for coverage
@daniloegea daniloegea force-pushed the fix_critical_assert_write_nm_conf branch from 6af5809 to 0edc613 Compare April 21, 2023 10:19
Copy link
Contributor

@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.

ACK, lgtm.

That's the same we do further down when writing the [ipv4]/[ipv6] sections.

@slyon slyon merged commit 810a0ef into canonical:main Apr 24, 2023
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