Bug 163617 - KGet does not download bzip2 files correctly
Summary: KGet does not download bzip2 files correctly
Status: RESOLVED FIXED
Alias: None
Product: kget
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: unspecified Linux
: NOR normal
Target Milestone: ---
Assignee: KGet authors
URL:
Keywords:
: 162421 (view as bug list)
Depends on:
Blocks:
 
Reported: 2008-06-09 16:07 UTC by Anne-Marie Mahfouf
Modified: 2008-08-26 18:59 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Anne-Marie Mahfouf 2008-06-09 16:07:22 UTC
Version:           2.0.80 (using 4.00.81 (KDE 4.0.81 >= 20080527), compiled sources)
Compiler:          gcc
OS:                Linux (i686) release 2.6.22.18-laptop-1mdv

I downloaded a bzip2 archive via KGet
http://quassel-irc.org/system/files/quassel-0.2.0-beta1.tar.bz2
and I saved it.
When I untarred it I got the following error:
quassel-0.2.0-beta1/src/icons/quassel.icns

bzip2: Data integrity error when decompressing.
        Input file = (stdin), output file = (stdout)

It is possible that the compressed file(s) have become corrupted.
You can use the -tvv option to test integrity of such files.

You can use the `bzip2recover' program to attempt to recover
data from undamaged sections of corrupted files.

tar: Unexpected EOF in archive
tar: Unexpected EOF in archive
tar: Error is not recoverable: exiting now


I tested the file by downloading it with wget in Konsole and I was able to untar it correctly.
file quassel-0.2.0-beta1.tar.bz2 and ls -la give the same information about the archive.
Comment 1 Anne-Marie Mahfouf 2008-06-09 16:11:14 UTC
wget
[kde4@localhost tmp]$ md5sum quassel-0.2.0-beta1.tar.bz2
246881ecc4d7e7a0eb98a2fa6bfbac64  quassel-0.2.0-beta1.tar.bz2

kget
[kde4@localhost ~]$ md5sum quassel-0.2.0-beta1.tar.bz2
6765baaa91165fdf28d1e3c0417b3bdf  quassel-0.2.0-beta1.tar.bz2
Comment 2 Anne-Marie Mahfouf 2008-06-09 16:19:48 UTC
KGet is used with the default settings: 5 segments and all defaults
Comment 3 Anne-Marie Mahfouf 2008-06-09 16:22:53 UTC
32 bit machine, thanks to boom1992 for guiding me on IRC and making this report perfect!
Comment 4 Jakub Stachowski 2008-06-09 19:16:27 UTC
Reason: quassel-irc.org does not support resuming (and returns response 200 instead of 206), but KGet blindly assumes that it does. As a result each fragment contains beginning of the file. When used with server that does support resuming, KGet downloads files correctly.
Comment 5 Anne-Marie Mahfouf 2008-06-09 20:38:22 UTC
Well I tried a totally random bzip2
http://dfn.dl.sourceforge.net/sourceforge/amsn/amsn-0.97RC1.tar.bz2
and it's the same so it seems that lots of servers do not support resuming.
Comment 6 Manolo Valdes 2008-06-15 01:25:36 UTC
So in that case. kget have to download the file only in the very first change?

you cant stop and resume or close kget and resume later?

if that is the case we need to make some changes.
btw any hints for how to implement this?
Comment 7 Urs Wolfer 2008-06-15 11:50:38 UTC
It would be good IMHO if KGet would show a warning for such a file when the user want to stop it / quit KGet that it is not possible to resume it.
Also multithreaded downloading should be disabled for such servers since that will not work.
If the user quits KGet or pauses the file, the download has to start from beginning again.
Comment 8 Lukas Appelhans 2008-06-18 13:00:07 UTC
*** Bug 162421 has been marked as a duplicate of this bug. ***
Comment 9 Urs Wolfer 2008-06-27 22:05:18 UTC
Please try again.

SVN commit 825276 by mvaldes

take into account the resuming capabilities of the transfer
this should fix bug:163617 
but i dont close it until more testing.
please feel free to check it and add some feedback
Comment 10 Lukas Appelhans 2008-08-26 18:59:04 UTC
This should be fixed in 4.1...

Lukas