summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLubomir Rintel <lkundrak@v3.sk>2014-11-21 15:31:57 +0100
committerLubomir Rintel <lkundrak@v3.sk>2014-11-21 15:32:37 +0100
commit13beedc83f0ac102d319dacdd3620d7af0186f46 (patch)
treeb31dc6b410a8c44ab4b6b85dada82b724288f837
parentc955070ca6a7a81e648ec6e0b5b7772b529233b0 (diff)
downloadNetworkManager-13beedc83f0ac102d319dacdd3620d7af0186f46.tar.gz
nmtui: Add a not reached assert to make compiler happy
nmt-editor.c: In function ‘nmt_editor_constructed’: nmt-editor.c:365:2: error: ‘page’ may be used uninitialized in this function [-Werror=maybe-uninitialized] add_sections_for_page (editor, grid, page); ^
-rw-r--r--clients/tui/nmt-editor.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/clients/tui/nmt-editor.c b/clients/tui/nmt-editor.c
index 1dbc4f84dc..11fe758dac 100644
--- a/clients/tui/nmt-editor.c
+++ b/clients/tui/nmt-editor.c
@@ -361,6 +361,8 @@ nmt_editor_constructed (GObject *object)
page = nmt_page_ethernet_new (priv->edit_connection, deventry);
else if (nm_connection_is_type (priv->edit_connection, NM_SETTING_WIRELESS_SETTING_NAME))
page = nmt_page_wifi_new (priv->edit_connection, deventry);
+ else
+ g_assert_not_reached ();
add_sections_for_page (editor, grid, page);
nmt_editor_grid_append (grid, NULL, nmt_newt_separator_new (), NULL);