mirror of
https://github.com/owntone/owntone-server.git
synced 2025-01-26 06:03:20 -05:00
Fix stop attempts during initial scan
This commit is contained in:
parent
5eb03dae42
commit
0df3ad01e1
@ -414,6 +414,7 @@ int main(int argc, char *argv[]) {
|
|||||||
/* read the configfile, if specified, otherwise
|
/* read the configfile, if specified, otherwise
|
||||||
* try defaults */
|
* try defaults */
|
||||||
config.stats.start_time=start_time=time(NULL);
|
config.stats.start_time=start_time=time(NULL);
|
||||||
|
config.stop=0;
|
||||||
|
|
||||||
if(config_read(configfile)) {
|
if(config_read(configfile)) {
|
||||||
fprintf(stderr,"Error reading config file (%s)\n",configfile);
|
fprintf(stderr,"Error reading config file (%s)\n",configfile);
|
||||||
@ -524,8 +525,6 @@ int main(int argc, char *argv[]) {
|
|||||||
DPRINTF(E_LOG,L_MAIN,"Scanned %d songs in %d seconds\n",db_get_song_count(),
|
DPRINTF(E_LOG,L_MAIN,"Scanned %d songs in %d seconds\n",db_get_song_count(),
|
||||||
end_time-start_time);
|
end_time-start_time);
|
||||||
|
|
||||||
config.stop=0;
|
|
||||||
|
|
||||||
while(!config.stop) {
|
while(!config.stop) {
|
||||||
if((config.rescan_interval) && (rescan_counter > config.rescan_interval)) {
|
if((config.rescan_interval) && (rescan_counter > config.rescan_interval)) {
|
||||||
if((config.always_scan) || (config_get_session_count())) {
|
if((config.always_scan) || (config_get_session_count())) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user