qcomicbook hangs when opening zip archives

Bug #225588 reported by akudewan on 2008-05-02
This bug affects 1 person
Affects Status Importance Assigned to Milestone
qcomicbook (Ubuntu)

Bug Description

When opening a zip archive in qcomicbook, the statusbar shows approximately 80% and the program hangs. Unzipping manually and opening it works fine.

I have also tried compiling from source, but the same problem occurs.

Using qcomicbook version 0.4.0-0ubuntu1 and Ubuntu Hardy.

akudewan (akudewan) wrote :

I found a workaround. In the file src/statusbar.cpp, commenting out the last line in the function "StatusBar::setProgress(int n, int total)" seems to solve the problem. (line 166: pbar->setValue(n);)

It seems to hang after the difference between the "n" and "total" variables is 4. Most probably a pointer thing, but I can't figure out what exactly...

Lucas Cardoso (lcardoso) wrote :

I can confirm this bug in Ubuntu Hardy 8.04. Strangely enough, it only happened after I reinstalled Gutsy and upgraded to Hardy (I had made a clean install of Hardy a couple of days ago and it qcomicbook worked perfectly).

Berti (bertrand-haut-gmail) wrote :

Confirmed on a fresh upgrade to Hardy 8.04. If someone has built a package with the proposed workaround, is it possible to distribute it ?

akudewan (akudewan) wrote :

@Berti: For some reason, the workaround I proposed isn't working consistently. You could try comix ( http://comix.sourceforge.net/ ) for the time being, or unzip the archives manually...

I hope this is fixed soon though, I like qcomicbook better.

Brian Murray (brian-murray) wrote :

Do you have a sample document that can be used to recreate this bug report? Additionally, what is the latest release of Ubuntu you've been able to recreate this bug with? Thanks in advance.

Changed in qcomicbook:
status: New → Incomplete
Yözen Hernández (yhernand) wrote :

I have experienced this bug ever since 8.04, and I still do in 8.10 with the latest updates. The % at which it hangs varies (sometimes 80%, 97%, and sometimes the progress bar turns completely blank.) QComicBook must be killed as it becomes completely unresponsive.

In 8.10, I have even experienced it hanging with .rar's (progress bar is blank in these cases) and the only way I can use QComicBook is by unarchiving the file and opening the folder with it.

I'll see if I can get a sample document up, but it should occur with any zip archive of jpgs, (or any rar of jpgs, for me).

Running qcomicbook in a terminal gives absolutely no output.

Rogue Jedi X (bor-svab) wrote :

I'm also experiencing the same problem. Unpacking the archives and then opening the folder works fine, while opening the archive files themselves with qcomicbook causes it to hang at usually 98%, thought the number differs from time to time.

Using Kubuntu 8.10 64-bit.

Brian Murray (brian-murray) wrote :

I've been able to recreate this with any of my zip archives so it'd be really helpful if a document that creates this bug could be added to the report.

Cork (cork) wrote :

I've been able to resolve all problems with rar, files except password protection by installing the non free unrar package.

zip files hangs what ever i do though. Adding a test file feels kinda unneeded cause any zip, what ever I do hangs.

Im using:
ubuntu 9.04
qcomicbook 0.4.0
unzip 5.52
zip 2.32

Juliano Ravasi (jravasi) wrote :

I can reproduce it here. It seems at least two bugs, one in Qt4 and another in qcomicbook.

The main GUI thread hangs in src/imgarchivesink.cpp, QComicBook::ImgArchiveSink::extract(const QString &, const QString &, ArchiveType), around line 221:

 extcnt = 0;
 pext->start(extprg, extargs);
 if (!pext->waitForFinished(5000))

pext is a QProcess*. The unzip command is executed, but the call to waitForFinished() never returns. Instead, it hangs in an infinite select(), that is, no file descriptors to monitor and infinite timeout. This happens *after* the command is executed and the zip is decompressed in /tmp. Whatever happens, Qt should not run a select() without any file descriptors to monitor.

The qcomicbook bug is that, according to Qt4 documentation, QProcess should not be used from the GUI thread.

Juliano Ravasi (jravasi) wrote :

I would like to ask other people having this issue if you have 64-bit installations, or if anyone is using 32-bit Ubuntu.

Juliano Ravasi (jravasi) wrote :

Forget the question about 64-bit. I found the bug (still don't know if it is qcomicbook's or Qt's).

Here is a patch to fix it (or at least, work around the problem). It disables UI updating when opening archives, but at least it doesn't hang anymore. It would probably need some redesign from the developer on this part, qcomicbook should not run processes using the main UI thread. Also, there seems to be a Qt bug as well, I'll ask Qt devs about it.

Changed in qcomicbook (Ubuntu):
status: Incomplete → New
Juliano Ravasi (jravasi) wrote :

A new version of QComicBook (0.4.1) was released to fix this bug. We could have an updated package.


Cork (cork) wrote :

Donno if this info is needed, but I can confirm that that package (0.4.1) fixes the problem for me.

Brian Murray (brian-murray) wrote :

qcomicbook has been updated to version 0.4.1 in Karmic so I'm setting this bug to Fix Released. Thanks everyone for your research and working on this bug report.

qcomicbook (0.4.1-1) unstable; urgency=low

  * New upstream release.
  * Build-Depends: libqt4-dev (>= 4.3.0).

 -- Brian Murray < <email address hidden>> Thu, 03 Sep 2009 16:45:26 +0100

Changed in qcomicbook (Ubuntu):
importance: Undecided → High
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers