src/gui/image/qbmphandler.cpp
changeset 33 3e2da88830cd
parent 18 2f34d5167611
--- a/src/gui/image/qbmphandler.cpp	Tue Jul 06 15:10:48 2010 +0300
+++ b/src/gui/image/qbmphandler.cpp	Wed Aug 18 10:37:55 2010 +0300
@@ -674,13 +674,15 @@
 
 bool QBmpHandler::canRead() const
 {
-    if (state == Ready) {
-        if (!canRead(device()))
-            return false;
+    if (state == Ready && !canRead(device()))
+        return false;
+
+    if (state != Error) {
         setFormat("bmp");
         return true;
     }
-    return state != Error;
+
+    return false;
 }
 
 bool QBmpHandler::canRead(QIODevice *device)