summaryrefslogtreecommitdiff
path: root/sphinx/builders
diff options
context:
space:
mode:
authorGeorg Brandl <georg@python.org>2014-01-10 15:07:17 +0100
committerGeorg Brandl <georg@python.org>2014-01-10 15:07:17 +0100
commit428ec87be0137b9ea3acf7ccf50cce773760b2e9 (patch)
tree2981fe3cd09f576d9a2e934b63a5f0db3c4b52e9 /sphinx/builders
parent7b058f3cff97c52e5cd29b6bec47ec49cbfe599a (diff)
downloadsphinx-428ec87be0137b9ea3acf7ccf50cce773760b2e9.tar.gz
Closes #1319: Do not crash if the ``html_logo`` file does not exist.
Diffstat (limited to 'sphinx/builders')
-rw-r--r--sphinx/builders/html.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/sphinx/builders/html.py b/sphinx/builders/html.py
index e00b91c3..ecc8a3b6 100644
--- a/sphinx/builders/html.py
+++ b/sphinx/builders/html.py
@@ -597,7 +597,9 @@ class StandaloneHTMLBuilder(Builder):
if self.config.html_logo:
logobase = path.basename(self.config.html_logo)
logotarget = path.join(self.outdir, '_static', logobase)
- if not path.isfile(logotarget):
+ if not path.isfile(logobase):
+ self.warn('logo file %r does not exist' % logobase)
+ elif not path.isfile(logotarget):
copyfile(path.join(self.confdir, self.config.html_logo),
logotarget)
if self.config.html_favicon: