summaryrefslogtreecommitdiffstats
path: root/src/htmlgen.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/htmlgen.cpp')
-rw-r--r--src/htmlgen.cpp13
1 files changed, 10 insertions, 3 deletions
diff --git a/src/htmlgen.cpp b/src/htmlgen.cpp
index aec995f..a0a46d7 100644
--- a/src/htmlgen.cpp
+++ b/src/htmlgen.cpp
@@ -275,9 +275,16 @@ void HtmlGenerator::writeStyleInfo(int part)
else // write user defined style sheet
{
QFileInfo cssfi(Config::htmlStyleSheet);
- startPlainFile(cssfi.fileName());
- t << fileToString(Config::htmlStyleSheet);
- endPlainFile();
+ if (!cssfi.exists() || !cssfi.isFile() || !cssfi.isReadable())
+ {
+ err("Error: style sheet %s does not exist or is not readable!", Config::htmlStyleSheet.data());
+ }
+ else
+ {
+ startPlainFile(cssfi.fileName());
+ t << fileToString(Config::htmlStyleSheet);
+ endPlainFile();
+ }
}
}
}