update: added update_global_init() and update_global_finish()
Those two functions are called when MPD starts and exits. It allows the update library to perform global initialization and deinitialization. The implementations are currently empty.
This commit is contained in:
parent
bd0653f440
commit
ced4abcd64
@ -416,6 +416,7 @@ int main(int argc, char *argv[])
|
||||
initPermissions();
|
||||
initPlaylist();
|
||||
decoder_plugin_init_all();
|
||||
update_global_init();
|
||||
|
||||
init_main_notify();
|
||||
|
||||
@ -497,6 +498,7 @@ int main(int argc, char *argv[])
|
||||
dc_deinit();
|
||||
pc_deinit();
|
||||
command_finish();
|
||||
update_global_finish();
|
||||
decoder_plugin_deinit_all();
|
||||
music_pipe_free();
|
||||
cleanUpPidFile();
|
||||
|
@ -580,3 +580,11 @@ void reap_update_task(void)
|
||||
progress = UPDATE_PROGRESS_IDLE;
|
||||
}
|
||||
}
|
||||
|
||||
void update_global_init(void)
|
||||
{
|
||||
}
|
||||
|
||||
void update_global_finish(void)
|
||||
{
|
||||
}
|
||||
|
@ -20,6 +20,10 @@
|
||||
#ifndef MPD_UPDATE_H
|
||||
#define MPD_UPDATE_H
|
||||
|
||||
void update_global_init(void);
|
||||
|
||||
void update_global_finish(void);
|
||||
|
||||
unsigned
|
||||
isUpdatingDB(void);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user