Prevent an unnecessary config file write.
authorCarl Hetherington <cth@carlh.net>
Fri, 6 Jul 2018 21:31:37 +0000 (22:31 +0100)
committerCarl Hetherington <cth@carlh.net>
Fri, 6 Jul 2018 21:31:37 +0000 (22:31 +0100)
src/lib/config.cc

index 8f1dd86ff763e17ec78f03950aa468cb1c0b4977..56ab16db7e0e72636cdbb8a343e6414bb317dd4b 100644 (file)
@@ -976,6 +976,10 @@ Config::read_cinemas (cxml::Document const & f)
 void
 Config::set_cinemas_file (boost::filesystem::path file)
 {
+       if (file == _cinemas_file) {
+               return;
+       }
+
        _cinemas_file = file;
 
        if (boost::filesystem::exists (_cinemas_file)) {