Fix some warnings from newer compilers

This commit is contained in:
Justin Maggard
2020-09-25 17:48:07 -07:00
committed by Justin Maggard
parent 9fba41008a
commit 9f1677825c
10 changed files with 35 additions and 22 deletions

View File

@ -104,7 +104,10 @@ raise_watch_limit(unsigned int limit)
if (!max_watches)
return;
if (!limit)
fscanf(max_watches, "%u", &limit);
{
if (fscanf(max_watches, "%u", &limit) < 1)
limit = 8192;
}
fprintf(max_watches, "%u", next_highest(limit));
fclose(max_watches);
}
@ -643,7 +646,7 @@ start_inotify(void)
if (setpriority(PRIO_PROCESS, 0, 19) == -1)
DPRINTF(E_WARN, L_INOTIFY, "Failed to reduce inotify thread priority\n");
sqlite3_release_memory(1<<31);
av_register_all();
lav_register_all();
while( !quitting )
{