Main: don't require mpd.conf on Android
Don't fail to start if mpd.conf does not exist; just use default values.
This commit is contained in:
parent
6ba0b029e6
commit
82ecebb393
@ -95,6 +95,7 @@
|
||||
#include "android/Environment.hxx"
|
||||
#include "android/Context.hxx"
|
||||
#include "fs/StandardDirectory.hxx"
|
||||
#include "fs/FileSystem.hxx"
|
||||
#include "org_musicpd_Bridge.h"
|
||||
#endif
|
||||
|
||||
@ -448,7 +449,8 @@ int mpd_main(int argc, char *argv[])
|
||||
if (!sdcard.IsNull()) {
|
||||
const auto config_path =
|
||||
AllocatedPath::Build(sdcard, "mpd.conf");
|
||||
if (!ReadConfigFile(config_path, error)) {
|
||||
if (FileExists(config_path) &&
|
||||
!ReadConfigFile(config_path, error)) {
|
||||
LogError(error);
|
||||
return EXIT_FAILURE;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user