settings: mark the connection as UNSAVED if it was modified in-memory

This commit is contained in:
Thomas Haller 2017-12-11 18:40:22 +01:00
parent e8299e30b8
commit 023ce50d21

View file

@ -691,7 +691,11 @@ nm_settings_connection_update (NMSettingsConnection *self,
nm_settings_connection_recheck_visibility (self);
set_persist_mode (self, persist_mode);
if ( replaced
&& persist_mode == NM_SETTINGS_CONNECTION_PERSIST_MODE_KEEP)
set_persist_mode (self, NM_SETTINGS_CONNECTION_PERSIST_MODE_UNSAVED);
else
set_persist_mode (self, persist_mode);
if (NM_IN_SET (persist_mode, NM_SETTINGS_CONNECTION_PERSIST_MODE_IN_MEMORY_ONLY,
NM_SETTINGS_CONNECTION_PERSIST_MODE_VOLATILE_ONLY))