On Sun, 2014-08-17 at 21:43 +0600, Alexander E. Patrakov wrote:
> 2014-08-17 16:43 GMT+06:00 Tanu Kaskinen <[email protected]>:
> > If there are unsaved changes, those need to be written to disk before
> > the module is unloaded, otherwise the changes are lost.
> > ---
> >  src/modules/module-device-restore.c | 4 +++-
> >  1 file changed, 3 insertions(+), 1 deletion(-)
> >
> > diff --git a/src/modules/module-device-restore.c 
> > b/src/modules/module-device-restore.c
> > index 031a62b..b7f172f 100644
> > --- a/src/modules/module-device-restore.c
> > +++ b/src/modules/module-device-restore.c
> > @@ -1321,8 +1321,10 @@ void pa__done(pa_module*m) {
> >      if (u->connection_unlink_hook_slot)
> >          pa_hook_slot_free(u->connection_unlink_hook_slot);
> >
> > -    if (u->save_time_event)
> > +    if (u->save_time_event) {
> >          u->core->mainloop->time_free(u->save_time_event);
> > +        pa_database_sync(u->database);
> > +    }
> >
> >      if (u->database)
> >          pa_database_close(u->database);
> 
> ACK.
> 
> This saves the database on module unload if there is already an
> intention to save it "later", which is the correct criterion.

Thanks, applied.

-- 
Tanu

_______________________________________________
pulseaudio-discuss mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/pulseaudio-discuss

Reply via email to