Bug 169079 - KHangman crashes on startup
Summary: KHangman crashes on startup
Status: RESOLVED WORKSFORME
Alias: None
Product: khangman
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: Ubuntu Linux
: NOR crash
Target Milestone: ---
Assignee: Anne-Marie Mahfouf
URL:
Keywords:
: 175804 178638 208919 (view as bug list)
Depends on:
Blocks:
 
Reported: 2008-08-13 23:37 UTC by Jonathan Thomas
Modified: 2012-01-05 23:58 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
khangman crashed when I open it (2.90 KB, application/octet-stream)
2008-12-09 17:08 UTC, Slash Network
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jonathan Thomas 2008-08-13 23:37:56 UTC
Version:           2.0 (using KDE 4.1.0)
Installed from:    Ubuntu Packages
Compiler:          gcc 
OS:                Linux

Pretty self-explanatory.

Terminal output:
khangman(7400) KEduVocDocument::KEduVocDocument: constructor done                    
khangman(7400) KHangMan::setLanguages: Languages  ()                                 
ASSERT failure in QList<T>::operator[]: "index out of range", file /usr/include/qt4/QtCore/qlist.h, line 401                                                                                  
KCrash: Application 'khangman' crashing...                                                     
sock_file=/home/jonathan/.kde/socket-jonathan-desktop/kdeinit4__0    

Backtrace:

Application: KHangMan (khangman), signal SIGABRT
[Thread debugging using libthread_db enabled]
[New Thread 0xb6003700 (LWP 7463)]
[KCrash handler]
#6  0xb7f28424 in __kernel_vsyscall ()
#7  0xb688b860 in raise () from /lib/tls/i686/cmov/libc.so.6
#8  0xb688d228 in abort () from /lib/tls/i686/cmov/libc.so.6
#9  0xb749c725 in qt_message_output () from /usr/lib/libQtCore.so.4
#10 0xb749c802 in qFatal () from /usr/lib/libQtCore.so.4
#11 0xb749c85c in qt_assert_x () from /usr/lib/libQtCore.so.4
#12 0x0805328e in KHangMan::loadSettings (this=0x9be9330)
    at /usr/include/qt4/QtCore/qlist.h:401
#13 0x08055beb in KHangMan (this=0x9be9330)
    at /build/buildd/kdeedu-4.1.0/khangman/src/khangman.cpp:69
#14 0x080598b1 in main (argc=1, argv=0xbfd42ce4)
    at /build/buildd/kdeedu-4.1.0/khangman/src/main.cpp:136
#0  0xb7f28424 in __kernel_vsyscall ()
Comment 1 FiNeX 2008-08-14 14:51:24 UTC
It seems fixed in current trunk where it doesn't crash.
Comment 2 Anne-Marie Mahfouf 2008-09-15 08:29:00 UTC
Jonathan, can you tell us if you still have this crash? If you do, please tell me the steps to reproduce (default settings? if not, language?...)

Many thanks in advance!
Comment 3 Jonathan Thomas 2008-09-15 13:56:50 UTC
This is still a problem with khangman in KDE 4.1.1. It does appear to be language related. If no language packages are installed, I get the assert/crash described in the original post. However, if a language pack such as kde-l10n-es is merely installed, the console output changes to something like this:

khangman(9418) KEduVocDocument::KEduVocDocument: constructor done
khangman(9418) KHangMan::setLanguages: Languages  ("es")         
khangman(9418) KHangMan::setAccent: in slot accent               
KCrash: Application 'khangman' crashing...

with the following backtrace:

Application: KHangMan (khangman), signal SIGSEGV
(no debugging symbols found)
(no debugging symbols found)
[Thread debugging using libthread_db enabled]
[New Thread 0xb616e6c0 (LWP 9602)]
[KCrash handler]
#6  0xb763cd72 in QString::operator= () from /usr/lib/libQtCore.so.4
#7  0x08056ccb in _start ()
#0  0xb8080424 in __kernel_vsyscall ()
Comment 4 Anne-Marie Mahfouf 2008-09-15 14:18:45 UTC
Is this a new install or do you have already an old config file? If so, can you backup your settings and retry with a clean config? ($KDEHOME/share/apps/khangman and $KDEHOME/share/config/khangmanrc)

Your crash report is not useful, you need debug info, look at 
http://techbase.kde.org/Development/Tutorials/Debugging/How_to_create_useful_crash_reports

Thanks in advance!
Comment 5 Jonathan Thomas 2008-09-15 14:27:54 UTC
Yes, this does happen with a clean installation. I removed khangmanrc to make sure of it. (There wasn't a directory in config/apps/, I guess it dies before it has a chance to create that...)

Anyway, here's a better backtrace. (I had forgotten that I uninstalled the debugging symbols. Sorry about that. ;-))

Application: KHangMan (khangman), signal SIGSEGV
[Thread debugging using libthread_db enabled]
[New Thread 0xb60de6c0 (LWP 10232)]
[KCrash handler]
#6  0xb75acd72 in QString::operator= () from /usr/lib/libQtCore.so.4
#7  0x08056ccb in Prefs::setLevelFile (v=@0x80697dc)
    at /build/buildd/kdeedu-4.1.1/obj-i486-linux-gnu/khangman/src/prefs.h:50
#8  0x08054814 in KHangMan::loadLevels (this=0x83ff1a8)
    at /build/buildd/kdeedu-4.1.1/khangman/src/khangman.cpp:296
#9  0x08055c03 in KHangMan (this=0x83ff1a8)
    at /build/buildd/kdeedu-4.1.1/khangman/src/khangman.cpp:72
#10 0x080598b1 in main (argc=1, argv=0xbfd09564)
    at /build/buildd/kdeedu-4.1.1/khangman/src/main.cpp:136
#0  0xb7ff0424 in __kernel_vsyscall ()


To clarify, this is the crash that occurs when the Spanish language package is merely installed.
Comment 6 Anne-Marie Mahfouf 2008-09-15 14:59:50 UTC
I'd prefer debugging it with English as it is shipped as default. 
I need you to paste the content of the KHangMan Ubuntu package you use please (all the files installed and the locations of them).
Thanks
Comment 7 Jonathan Thomas 2008-09-15 16:57:11 UTC
Here is the file list:

jonathan@jonathan-desktop:~/$ dpkg -L khangman
/.                                                          
/usr                                                        
/usr/share                                                  
/usr/share/doc                                              
/usr/share/doc/khangman                                     
/usr/share/doc/khangman/copyright                           
/usr/share/doc/kde4                                         
/usr/share/doc/kde4/HTML                                    
/usr/share/doc/kde4/HTML/en                                 
/usr/share/doc/kde4/HTML/en/khangman                        
/usr/share/doc/kde4/HTML/en/khangman/index.cache.bz2        
/usr/share/doc/kde4/HTML/en/khangman/index.docbook          
/usr/share/doc/kde4/HTML/en/khangman/man-khangman.6.docbook 
/usr/share/doc/kde4/HTML/en/khangman/khangman-desert.png    
/usr/share/doc/kde4/HTML/en/khangman/games-hint.png         
/usr/share/doc/kde4/HTML/en/khangman/document-new.png       
/usr/share/doc/kde4/HTML/en/khangman/settings-languages.png 
/usr/share/doc/kde4/HTML/en/khangman/getnewstuff.png        
/usr/share/doc/kde4/HTML/en/khangman/settings-timers.png    
/usr/share/doc/kde4/HTML/en/khangman/application-exit.png   
/usr/share/doc/kde4/HTML/en/khangman/khangman-main.png      
/usr/share/doc/kde4/HTML/en/khangman/settings-general.png   
/usr/share/kde4                                             
/usr/share/kde4/config                                      
/usr/share/kde4/config/khangman.knsrc                       
/usr/share/kde4/apps                                        
/usr/share/kde4/apps/khangman                               
/usr/share/kde4/apps/khangman/khangmanui.rc                 
/usr/share/kde4/apps/khangman/pics                          
/usr/share/kde4/apps/khangman/pics/desert                   
/usr/share/kde4/apps/khangman/pics/desert/khangman_desert.svg
/usr/share/kde4/apps/khangman/pics/sea                       
/usr/share/kde4/apps/khangman/pics/sea/khangman_sea.svg      
/usr/share/kde4/apps/khangman/sounds                         
/usr/share/kde4/apps/khangman/sounds/new_game.ogg            
/usr/share/kde4/apps/khangman/sounds/EW_Dialogue_Appear.ogg  
/usr/share/kde4/apps/khangman/fonts                          
/usr/share/kde4/apps/khangman/fonts/Dustismo_Roman.ttf       
/usr/share/kde4/apps/khangman/fonts/Domestic_Manners.ttf     
/usr/share/kde4/config.kcfg                                  
/usr/share/kde4/config.kcfg/khangman.kcfg                    
/usr/share/applications                                      
/usr/share/applications/kde4                                 
/usr/share/applications/kde4/khangman.desktop                
/usr/share/icons                                             
/usr/share/icons/hicolor                                     
/usr/share/icons/hicolor/128x128                             
/usr/share/icons/hicolor/128x128/apps                        
/usr/share/icons/hicolor/128x128/apps/khangman.png           
/usr/share/icons/hicolor/16x16                               
/usr/share/icons/hicolor/16x16/apps                          
/usr/share/icons/hicolor/16x16/apps/khangman.png
/usr/share/icons/hicolor/22x22
/usr/share/icons/hicolor/22x22/apps
/usr/share/icons/hicolor/22x22/apps/khangman.png
/usr/share/icons/hicolor/32x32
/usr/share/icons/hicolor/32x32/apps
/usr/share/icons/hicolor/32x32/apps/khangman.png
/usr/share/icons/hicolor/48x48
/usr/share/icons/hicolor/48x48/apps
/usr/share/icons/hicolor/48x48/apps/khangman.png
/usr/share/icons/hicolor/64x64
/usr/share/icons/hicolor/64x64/apps
/usr/share/icons/hicolor/64x64/apps/khangman.png
/usr/share/icons/hicolor/scalable
/usr/share/icons/hicolor/scalable/apps
/usr/share/icons/hicolor/scalable/apps/khangman.svgz
/usr/bin
/usr/bin/khangman
/usr/share/doc/khangman/README
/usr/share/doc/khangman/changelog.Debian.gz
/usr/share/doc/kde4/HTML/en/khangman/common
Comment 8 Anne-Marie Mahfouf 2008-10-09 11:30:07 UTC
This happens when no vocabulary files are shipped with KHangMan. In KHangMan source dir there is a data/ folder containing English files which should be installed. If the distribution does not choose to install them, KHangMan crashes as KHangMan is done to load a file.
I could add a KMessageBox but really this is a stupid case which should be fixed on the distribution side. A KMessageBox will not really help the user anyway.
Comment 9 Dario Andres 2008-12-06 14:44:13 UTC
*** Bug 175804 has been marked as a duplicate of this bug. ***
Comment 10 Slash Network 2008-12-09 17:08:17 UTC
Created attachment 29179 [details]
khangman crashed when I open it

khangman crashed when I open it.
Comment 11 Anne-Marie Mahfouf 2008-12-09 17:34:15 UTC
For the person from comment 10 your backtrace is useless, you need to install the debug packages from your distribution to get a better one.

If you are using Ubuntu or derived though it is a packaging issue that is reported upstream I think.
Comment 12 Anne-Marie Mahfouf 2009-01-06 21:06:08 UTC
*** Bug 178638 has been marked as a duplicate of this bug. ***
Comment 13 Christoph Feck 2012-01-05 23:58:47 UTC
*** Bug 208919 has been marked as a duplicate of this bug. ***