Message ID | 20181129021255.32632-1-sam@mendozajonas.com |
---|---|
State | Accepted |
Headers | show |
Series | discover: Display warning if saving config fails | expand |
On Thu, 2018-11-29 at 13:12 +1100, Samuel Mendoza-Jonas wrote: > Signed-off-by: Samuel Mendoza-Jonas <sam@mendozajonas.com> Merged as c8769182 > --- > discover/device-handler.c | 5 ++++- > 1 file changed, 4 insertions(+), 1 deletion(-) > > diff --git a/discover/device-handler.c b/discover/device-handler.c > index 271b9880..729ed2c0 100644 > --- a/discover/device-handler.c > +++ b/discover/device-handler.c > @@ -1501,8 +1501,11 @@ void device_handler_update_config(struct device_handler *handler, > int rc; > > rc = config_set(config); > - if (rc) > + if (rc) { > + device_handler_status_err(handler, > + "Failed to update configuration!"); > return; > + } > > discover_server_notify_config(handler->server, config); > device_handler_update_lang(config->lang);
diff --git a/discover/device-handler.c b/discover/device-handler.c index 271b9880..729ed2c0 100644 --- a/discover/device-handler.c +++ b/discover/device-handler.c @@ -1501,8 +1501,11 @@ void device_handler_update_config(struct device_handler *handler, int rc; rc = config_set(config); - if (rc) + if (rc) { + device_handler_status_err(handler, + "Failed to update configuration!"); return; + } discover_server_notify_config(handler->server, config); device_handler_update_lang(config->lang);
Signed-off-by: Samuel Mendoza-Jonas <sam@mendozajonas.com> --- discover/device-handler.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)