Diffstat (limited to 'noncore/apps/tinykate/libkate/document') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/apps/tinykate/libkate/document/katebuffer.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/noncore/apps/tinykate/libkate/document/katebuffer.cpp b/noncore/apps/tinykate/libkate/document/katebuffer.cpp index 4c15fd0..d89edbd 100644 --- a/noncore/apps/tinykate/libkate/document/katebuffer.cpp +++ b/noncore/apps/tinykate/libkate/document/katebuffer.cpp | |||
@@ -72,7 +72,10 @@ KWBuffer::insertFile(int line, const QString &file, QTextCodec *codec) | |||
72 | } | 72 | } |
73 | clear(); | 73 | clear(); |
74 | QFile iofile(file); | 74 | QFile iofile(file); |
75 | iofile.open(IO_ReadOnly); | 75 | if (!iofile.open(IO_ReadOnly)) { |
76 | owarn << "failed to open file " << iofile.name() << oendl; | ||
77 | return; | ||
78 | } | ||
76 | QTextStream stream(&iofile); | 79 | QTextStream stream(&iofile); |
77 | stream.setCodec(codec); | 80 | stream.setCodec(codec); |
78 | QString qsl; | 81 | QString qsl; |