Bug 173448 - Strigi crashes when analyzing a .gz file that is equal to its own content (SIGSEGV)
Summary: Strigi crashes when analyzing a .gz file that is equal to its own content (SI...
Status: RESOLVED FIXED
Alias: None
Product: unknown
Classification: Bugzilla Internals
Component: general (show other bugs)
Version: unspecified
Platform: openSUSE Linux
: NOR crash
Target Milestone: ---
Assignee: Jos van den Oever
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-10-24 18:04 UTC by Eldar Abusalimov
Modified: 2009-01-03 13:04 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 Eldar Abusalimov 2008-10-24 18:04:51 UTC
Version:           1.1 (using KDE 4.1.2)
OS:                Linux
Installed from:    SuSE RPMs

First of all please try 

wget 'http://www.maximumcompression.com/selfgz.gz'
gunzip selfgz.gz
wget 'http://www.maximumcompression.com/selfgz.gz'
cmp selfgz.gz selfgz 

This means that the archive contains an archive which is exactly (byte-by-byte) the same as its parent archive.


This causes SIGSEGV when moving the mouse cursor over the file item in Dolphin.


Back trace looks like:

Приложение: Dolphin (dolphin), сигнал SIGSEGV
[?1034h(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)

//< a lot of (no debugging symbols found) >

(no debugging symbols found)
[KCrash handler]
#6  0xb7a1ae06 in ?? () from /usr/lib/libstreamanalyzer.so.0
#7  0xb79ea56e in Strigi::AnalysisResult::indexChild ()
   from /usr/lib/libstreamanalyzer.so.0
#8  0xb7a254af in ?? () from /usr/lib/libstreamanalyzer.so.0
#9  0xb7a1ae3f in ?? () from /usr/lib/libstreamanalyzer.so.0
#10 0xb79ea56e in Strigi::AnalysisResult::indexChild ()
   from /usr/lib/libstreamanalyzer.so.0

// <repeating - infinite recursion>

   from /usr/lib/libstreamanalyzer.so.0
#380 0xb78b74af in ?? () from /usr/lib/libstreamanalyzer.so.0
#381 0xb78ace3f in ?? () from /usr/lib/libstreamanalyzer.so.0
#382 0xb787c56e in Strigi::AnalysisResult::indexChild ()
   from /usr/lib/libstreamanalyzer.so.0
#383 0xb78b74af in ?? () from /usr/lib/libstreamanalyzer.so.0
#384 0xb78ace3f in ?? () from /usr/lib/libstreamanalyzer.so.0
#385 0xb787c56e in Strigi::AnalysisResult::indexChild ()
   from /usr/lib/libstreamanalyzer.so.0
#386 0xb78b74af in ?? () from /usr/lib/libstreamanalyzer.so.0
#387 0xb78ace3f in ?? () from /usr/lib/libstreamanalyzer.so.0
#388 0xb787c56e in Strigi::AnalysisResult::indexChild ()
   from /usr/lib/libstreamanalyzer.so.0
#389 0xb78b74af in ?? () from /usr/lib/libstreamanalyzer.so.0
#390 0xb78ace3f in ?? () from /usr/lib/libstreamanalyzer.so.0
#391 0xb7d5bf2e in ?? () from /usr/lib/libkio.so.5
#392 0xb7d5dcb5 in KFileMetaInfo::KFileMetaInfo () from /usr/lib/libkio.so.5
#393 0x0808144c in _start ()
#0  0xffffe430 in __kernel_vsyscall ()


How to Reproduce:

download 'http://www.maximumcompression.com/selfgz.gz';
open Dolphin, make sure that View -> Panels -> Information is on, (F11 to toggle);
move the mouse cursor over the downloaded selfgz.gz;
Dolphin crashes with sigsegv.


I haven't any free time now to fix this bug by myself, so I'm writing here.

Thank you,
Eldar.
Comment 1 Frank Reininghaus 2008-10-24 21:04:42 UTC
Thanks for the bug report. I can confirm this in trunk rev. 875277. The four functions that get called over and over again are

#6  0xb6117ec7 in Strigi::StreamAnalyzerPrivate::analyze () from /home/kde-devel/kde/lib/libstreamanalyzer.so.0
#7  0xb61189bb in Strigi::StreamAnalyzer::analyze () from /home/kde-devel/kde/lib/libstreamanalyzer.so.0
#8  0xb60d6c00 in Strigi::AnalysisResult::indexChild () from /home/kde-devel/kde/lib/libstreamanalyzer.so.0
#9  0xb61293f5 in GZipEndAnalyzer::analyze () from /home/kde-devel/kde/lib/libstreamanalyzer.so.0

(I'm not getting line numbers for Strigi although it's built from source, probably needs an extra option).

The problem appears to be in Strigi, but I don't know what the official way to report Strigi bugs is (there seems to be no 'Strigi' product or component in bugs.kde.org).

Comment 2 Frank Reininghaus 2008-10-24 21:09:28 UTC
Reassigning to Jos van den Oever. Jos, for your information: I'm running Strigi from trunk/kdesupport, revision 875277.
Comment 3 Eldar Abusalimov 2008-10-24 22:32:23 UTC
Thank you, Frank!
Comment 4 Pino Toscano 2008-10-25 12:45:14 UTC
(Strigi is not "kdelibs" but "unknown". And technically its bug tracking system is on sourceforge.)
Comment 5 Jos van den Oever 2009-01-03 13:04:38 UTC
SVN commit 904845 by vandenoever:

Fix bug where a gz archive that contains a file that is identical to the
original archive. The depth variable of AnalysisResult would jump from
value 127 to -128. The depth is now limited to 127. Having files nested
127 levels deep is very uncommon.

The self-referential gz file is included in the testdata directory.

BUG:173448

 M  +2 -1      src/streamanalyzer/analysisresult.cpp  
 A             testdata/data/selfgz.gz  


WebSVN link: http://websvn.kde.org/?view=rev&revision=904845