[gtk-doc] fixxref: don't scan dirs that don't exist
- From: Stefan Sauer <stefkost src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk-doc] fixxref: don't scan dirs that don't exist
- Date: Sun, 23 Apr 2017 15:39:05 +0000 (UTC)
commit 8af1966e2bcce3db2b0124e396e34946f7c0ec90
Author: Stefan Sauer <ensonic users sf net>
Date: Sun Apr 23 17:35:49 2017 +0200
fixxref: don't scan dirs that don't exist
Fixes #781443
gtkdoc/fixxref.py | 8 +++++---
1 files changed, 5 insertions(+), 3 deletions(-)
---
diff --git a/gtkdoc/fixxref.py b/gtkdoc/fixxref.py
index 406a71e..4893b87 100755
--- a/gtkdoc/fixxref.py
+++ b/gtkdoc/fixxref.py
@@ -120,10 +120,12 @@ def ScanIndices(scan_dir, use_absolute_links):
logging.info('Scanning index directory: %s, absolute: %d', scan_dir, use_absolute_links)
- # This array holds any subdirectories found.
- subdirs = []
-
# TODO(ensonic): this code is the same as in rebase.py
+ if not os.path.isdir(scan_dir):
+ logging.info('Cannot open dir "%s"', scan_dir)
+ return
+
+ subdirs = []
for entry in os.listdir(scan_dir):
full_entry = os.path.join(scan_dir, entry)
if os.path.isdir(full_entry):
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]