[Okular-devel] [Bug 179447] New: [Patch][Testcase] Empty comicbook crash

David Palacio dpalacio at uninorte.edu.co
Sat Jan 3 03:46:44 CET 2009


http://bugs.kde.org/show_bug.cgi?id=179447

           Summary: [Patch][Testcase] Empty comicbook crash
           Product: okular
           Version: unspecified
          Platform: Compiled Sources
        OS/Version: unspecified
            Status: UNCONFIRMED
          Severity: crash
          Priority: NOR
         Component: Comicbook backend
        AssignedTo: okular-devel at kde.org
        ReportedBy: dpalacio at uninorte.edu.co


Version:            (using Devel)
Installed from:    Compiled sources

When a cbz/cbr file contains zero image files the generator in the Okular core
is undefined causing this crash:

#0  0x00007f4efe9e5b0a in Okular::Document::openDocument (this=0x1c1ba00,
docFile=@0x7fff12f1b7b0, url=<value optimized out>, _mime=<value optimized
out>)
    at ../../okular/core/document.cpp:1663
#1  0x00007f4efbb018b0 in Part::openFile (this=0x1b80420) at
../../okular/part.cpp:874
#2  0x00007f4f0298af34 in KParts::ReadOnlyPart::openUrl (this=0x1b80420,
url=<value optimized out>) at ../../kparts/part.cpp:558


Patch for the Comicbook generator. Or maybe the fix should go instead inside
Okular for 0 pages opened documents.
Index: document.cpp
===================================================================
--- document.cpp        (revisión: 900827)
+++ document.cpp        (copia de trabajo)
@@ -105,7 +105,7 @@
         return false;
     }

-    return true;
+    return mPageMap.size() > 0;
 }

 void Document::close()


Testcase is the attachment in the next message


-- 
Configure bugmail: http://bugs.kde.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


More information about the Okular-devel mailing list