mirror of
https://github.com/clementine-player/Clementine
synced 2025-02-01 11:56:45 +01:00
Fix a crash on startup after disabling watching the library for changes. Fixes issue 2585
(cherry picked from commit 2e49e89e7b5c5a0ebaa352e429f3e573a1fa778f)
This commit is contained in:
parent
dea9fbec95
commit
d5fcc1a24e
@ -695,7 +695,9 @@ void LibraryWatcher::ReloadSettings() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (!monitor_ && was_monitoring_before) {
|
if (!monitor_ && was_monitoring_before) {
|
||||||
|
if (fs_watcher_) {
|
||||||
fs_watcher_->Clear();
|
fs_watcher_->Clear();
|
||||||
|
}
|
||||||
} else if (monitor_ && !was_monitoring_before) {
|
} else if (monitor_ && !was_monitoring_before) {
|
||||||
// Add all directories to all QFileSystemWatchers again
|
// Add all directories to all QFileSystemWatchers again
|
||||||
foreach (const DirData& data, watched_dirs_.values()) {
|
foreach (const DirData& data, watched_dirs_.values()) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user