Main: convert int
return types to void
This commit is contained in:
parent
155c915733
commit
93ab957800
13
src/Main.cxx
13
src/Main.cxx
@ -385,11 +385,11 @@ main(int argc, char *argv[]) noexcept
|
|||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
static int
|
static void
|
||||||
mpd_main_after_fork(const ConfigData &raw_config,
|
mpd_main_after_fork(const ConfigData &raw_config,
|
||||||
const Config &config);
|
const Config &config);
|
||||||
|
|
||||||
static inline int
|
static inline void
|
||||||
MainOrThrow(int argc, char *argv[])
|
MainOrThrow(int argc, char *argv[])
|
||||||
{
|
{
|
||||||
struct options options;
|
struct options options;
|
||||||
@ -471,7 +471,7 @@ MainOrThrow(int argc, char *argv[])
|
|||||||
AtScopeExit() { daemonize_finish(); };
|
AtScopeExit() { daemonize_finish(); };
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
return mpd_main_after_fork(raw_config, config);
|
mpd_main_after_fork(raw_config, config);
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef ANDROID
|
#ifdef ANDROID
|
||||||
@ -482,14 +482,15 @@ int mpd_main(int argc, char *argv[]) noexcept
|
|||||||
AtScopeExit() { log_deinit(); };
|
AtScopeExit() { log_deinit(); };
|
||||||
|
|
||||||
try {
|
try {
|
||||||
return MainOrThrow(argc, argv);
|
MainOrThrow(argc, argv);
|
||||||
|
return EXIT_SUCCESS;
|
||||||
} catch (...) {
|
} catch (...) {
|
||||||
LogError(std::current_exception());
|
LogError(std::current_exception());
|
||||||
return EXIT_FAILURE;
|
return EXIT_FAILURE;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static int
|
static void
|
||||||
mpd_main_after_fork(const ConfigData &raw_config, const Config &config)
|
mpd_main_after_fork(const ConfigData &raw_config, const Config &config)
|
||||||
{
|
{
|
||||||
ConfigureFS(raw_config);
|
ConfigureFS(raw_config);
|
||||||
@ -622,8 +623,6 @@ mpd_main_after_fork(const ConfigData &raw_config, const Config &config)
|
|||||||
instance->BeginShutdownPartitions();
|
instance->BeginShutdownPartitions();
|
||||||
|
|
||||||
delete instance->client_list;
|
delete instance->client_list;
|
||||||
|
|
||||||
return EXIT_SUCCESS;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef ANDROID
|
#ifdef ANDROID
|
||||||
|
Loading…
Reference in New Issue
Block a user