Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 62547 - kwrite and kate 3.3.3 crash when trying to open binary files
Summary: kwrite and kate 3.3.3 crash when trying to open binary files
Status: RESOLVED UPSTREAM
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] KDE (show other bugs)
Hardware: All All
: High normal (vote)
Assignee: Gentoo KDE team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-09-01 12:47 UTC by crusaderky
Modified: 2005-01-01 10:12 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
A file that provokes the crash (Etherna.rar,327.97 KB, application/octet-stream)
2004-09-02 06:01 UTC, crusaderky
Details

Note You need to log in before you can comment on or make changes to this bug.
Description crusaderky 2004-09-01 12:47:37 UTC
They crash on start. I've tried with several PDFs (file size 7 - 35 Mb) and one RAR (file size 300kb). I could open another RAR (270kb) successfully, though.
Comment 1 Gregorio Guidi (RETIRED) gentoo-dev 2004-09-01 15:40:41 UTC
I assume it is 3.3.0. Haven't you got a backtrace?

Tried running kate/kwrite fom a console to see if there are useful messages?

Tried truncating/modifying the crashing file to get the smallest case that shows the bug?

Does it happen with a very large text file?

Maybe you can attach the 300k one...
Comment 2 Carsten Lohrke (RETIRED) gentoo-dev 2004-09-02 05:56:33 UTC
Can reproduce it. Very nice:

#5  0x40f73db0 in QLatin15Codec::toUnicode(char const*, int) const ()
   from /usr/qt/3/lib/libqt-mt.so.3
#6  0x40f7153f in QTextStatelessDecoder::toUnicode(char const*, int) ()
   from /usr/qt/3/lib/libqt-mt.so.3
#7  0x41bf5564 in KateFileLoader::readLine() (this=0xbfffd600)
    at katebuffer.cpp:165
#8  0x41bf239b in KateBufBlock::fillBlock(KateFileLoader*) (this=0x81f69c0, 
    stream=0xbfffd600) at katebuffer.cpp:1123
#9  0x41bf2143 in KateBufBlock (this=0x81f69c0, parent=0xffffff5c, prev=0x0, 
    next=0xffffff5c, stream=0xbfffd600) at katebuffer.cpp:1071
#10 0x41bf0042 in KateBuffer::openFile(QString const&) (this=0x81aad10, 
    m_file=@0x81f69c0) at katebuffer.cpp:437
#11 0x41c195e5 in KateDocument::openFile(KIO::Job*) (this=0x81d13c0, 
    job=0xbfffd6c0) at katedocument.cpp:2532
#12 0x41c19477 in KateDocument::openFile() (this=0xffffff5c)
    at katedocument.cpp:2504
#13 0x41c18f65 in KateDocument::openURL(KURL const&) (this=0x81d13c0, 
    url=@0xbfffd790) at katedocument.cpp:2413
#14 0x419759cd in KateDocManager::openURL(KURL const&, QString const&, unsigned*) (this=0x815e2a8, url=@0x85b28a8, encoding=@0xbfffd9c8, id=0xbfffd84c)
    at katedocmanager.cpp:232
#15 0x4198e507 in KateViewManager::openURL(KURL const&, QString const&, bool) (
    this=0x82dffc0, url=@0xffffff5c, encoding=@0xffffff5c, activate=false)
    at kateviewmanager.cpp:504
#16 0x4198e191 in KateViewManager::slotDocumentOpen() (this=0x82dffc0)
    at kateviewmanager.cpp:453
#17 0x4198c431 in KateViewManager::qt_invoke(int, QUObject*) (this=0x82dffc0, 
    _id=61, _o=0xbfffda90) at kateviewmanager.moc:240
#18 0x40c759bc in QObject::activate_signal(QConnectionList*, QUObject*) ()
   from /usr/qt/3/lib/libqt-mt.so.3
#19 0x40c757e4 in QObject::activate_signal(int) ()
   from /usr/qt/3/lib/libqt-mt.so.3
#20 0x404f3f80 in KAction::activated() (this=0xffffff5c) at kaction.moc:157
#21 0x404f393f in KAction::slotActivated() (this=0xffffff5c)
    at kaction.cpp:1057
#22 0x404f4226 in KAction::qt_invoke(int, QUObject*) (this=0x834c610, _id=14, 
    _o=0xbfffdba0) at kaction.moc:181
#23 0x40c759bc in QObject::activate_signal(QConnectionList*, QUObject*) ()
   from /usr/qt/3/lib/libqt-mt.so.3
#24 0x40fb3fda in QSignal::signal(QVariant const&) ()
   from /usr/qt/3/lib/libqt-mt.so.3
#25 0x40c8fb6d in QSignal::activate() () from /usr/qt/3/lib/libqt-mt.so.3
#26 0x40d7c569 in QPopupMenu::mouseReleaseEvent(QMouseEvent*) ()
   from /usr/qt/3/lib/libqt-mt.so.3
#27 0x40caba37 in QWidget::event(QEvent*) () from /usr/qt/3/lib/libqt-mt.so.3
#28 0x40c1957f in QApplication::internalNotify(QObject*, QEvent*) ()
   from /usr/qt/3/lib/libqt-mt.so.3
#29 0x40c18a33 in QApplication::notify(QObject*, QEvent*) ()
   from /usr/qt/3/lib/libqt-mt.so.3
#30 0x4079687b in KApplication::notify(QObject*, QEvent*) (this=0xbfffe6d0, 
    receiver=0x83928b8, event=0xbfffe180) at kapplication.cpp:495
#31 0x40bad7eb in QETWidget::translateMouseEvent(_XEvent const*) ()
   from /usr/qt/3/lib/libqt-mt.so.3
#32 0x40bab833 in QApplication::x11ProcessEvent(_XEvent*) ()
   from /usr/qt/3/lib/libqt-mt.so.3
#33 0x40bc29b4 in QEventLoop::processEvents(unsigned) ()
   from /usr/qt/3/lib/libqt-mt.so.3
#34 0x40c2b748 in QEventLoop::enterLoop() () from /usr/qt/3/lib/libqt-mt.so.3
#35 0x40c2b5f8 in QEventLoop::exec() () from /usr/qt/3/lib/libqt-mt.so.3
#36 0x40c197d1 in QApplication::exec() () from /usr/qt/3/lib/libqt-mt.so.3
#37 0x40960b57 in kdemain (argc=-164, argv=0xffffff5c) at katemain.cpp:106
#38 0x4095da56 in kdeinitmain (argc=-164, argv=0xffffff5c) at kate_dummy.cpp:2
#39 0x0804dc0f in launch (argc=1, _name=0x80db2dc "kate", 
    args=0x80db2e1 "\001", cwd=0x0, envc=1, envs=0x80db2f2 "", 
    reset_env=false, tty=0x0, avoid_loops=false, 
    startup_id_str=0xffffff5c <Address 0xffffff5c out of bounds>)
    at kinit.cpp:599
#40 0x0804f0e9 in handle_launcher_request (sock=8) at kinit.cpp:1163
#41 0x0804f65e in handle_requests (waitForPid=0) at kinit.cpp:1364
#42 0x08050717 in main (argc=3, argv=0xbfffeeb4, envp=0xffffff5c)
    at kinit.cpp:1817


Anyone keen to report upstream?
Comment 3 crusaderky 2004-09-02 06:01:19 UTC
Created attachment 38754 [details]
A file that provokes the crash
Comment 4 Gregorio Guidi (RETIRED) gentoo-dev 2004-09-03 09:52:47 UTC
Can someone confirm that this happens when reading the bogus file only with
charset ISO8859-15? And also that in general opening a binary file (a file with '\0' character inside) produces a text noticeably smaller than the 
original?
Comment 5 crusaderky 2004-09-03 10:03:34 UTC
ISO 8859-15: crashes
ISO 8859-1: opened, but truncated after 2-3 lines
UTF-8: correctly opened
Comment 6 Gregorio Guidi (RETIRED) gentoo-dev 2004-09-03 10:57:08 UTC
reported with a possible explanation:

http://bugs.kde.org/show_bug.cgi?id=88788
Comment 7 Caleb Tennis (RETIRED) gentoo-dev 2004-12-08 18:13:58 UTC
looks to be fixed in 3.3.2
Comment 8 crusaderky 2004-12-09 22:26:58 UTC
Not for me. As soon as I set the charset to ISO-8859-15, it crashes as usual.
Comment 9 Gregorio Guidi (RETIRED) gentoo-dev 2004-12-12 07:34:44 UTC
Probably the code was not changed for the 3.3 branch, it will be fixed in kde-3.4.
Comment 10 Gregorio Guidi (RETIRED) gentoo-dev 2005-01-01 10:12:02 UTC
closing.