]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/relocate.cc
* config.make.in (datadir): Add datarootdir to silence autoconf.
[lilypond.git] / lily / relocate.cc
index 8cb2b0861f25636ad4a01b3d603777e47f892a5a..d7f7888c4a6ecdf7e2d0401b8be4af941caecd26 100644 (file)
@@ -394,14 +394,11 @@ read_relocation_file (string filename)
 void
 read_relocation_dir (string dirname)
 {
-  DIR *dir = opendir  (dirname.c_str ());
-
-  while (struct dirent *ent = readdir (dir))
-    {
-      File_name name (ent->d_name);
-      if (name.ext_ == "reloc")
-       {
-         read_relocation_file (dirname + "/" + name.to_string ());
-       }
-    }
+  if (DIR *dir = opendir (dirname.c_str ()))
+    while (struct dirent *ent = readdir (dir))
+      {
+       File_name name (ent->d_name);
+       if (name.ext_ == "reloc")
+           read_relocation_file (dirname + "/" + name.to_string ());
+      }
 }