Export to GitHub

rolisteam - issue #6

"Nouveau PJ" arrête le programme


Posted on Oct 6, 2009 by Swift Rhino

Bonsoir, En essayant un peu le logiciel, je suis tombé sur un bug :

1) Lancer rolisteam 2) Fenêtre de connexion, saisie des éléments : Nom = "Tristan", Vous êtes = "MJ", Votre ordinateur est = "Serveur" appuis sur bouton "Connexion" 3) Ecran principal, cadre de droite "Joueurs connectés", appuis sur bouton "Nouveau PJ" 4) le programme se ferme sans message.

Détail de la console : [tristan@localhost rolisteam]$ ./bin/rolisteam Abandon [tristan@localhost rolisteam]$

Y-a-t'il un moyen d'obtenir des informations de débug lors du lancement du programme (via un --debug ou autre) ? Je pourrais ainsi vous donner des informations plus détaillées sur ce qui se passe.

Tristan.

Comment #1

Posted on Oct 7, 2009 by Happy Hippo

Il faut lancer rolisteam avec gdb. je ne sais pas si vous êtes familier avec gdb:

en console : gdb rolisteam Reproduire le bug quand gdb signale le problème, il faut taper "where" ça indique la pile d'exécution du programme, je verrais ou ça plante. Je n'arrive pas à reproduire le bug.

Comment #2

Posted on Oct 7, 2009 by Swift Rhino

Bonjour,

J'ai suivi vos instructions, je ne suis pas familier avec gdb mais comme je fait du dev (c'est mon métier depuis plus de 11 ans) ça vient vite ;-)

Voici le résultat :

[tristan@localhost bin]$ gdb rolisteam GNU gdb 6.8-6mdv2009.1 (Mandriva Linux release 2009.1) Copyright (C) 2008 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later http://gnu.org/licenses/gpl.html This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type "show copying" and "show warranty" for details. This GDB was configured as "x86_64-mandriva-linux-gnu"... (gdb) run Starting program: /home/tristan/workspace/rolisteam/bin/rolisteam [Thread debugging using libthread_db enabled] [New Thread 0x7f660cef7700 (LWP 15963)] [New Thread 0x7f65fc1a7950 (LWP 16299)] [New Thread 0x7f65faaf2950 (LWP 16318)] [New Thread 0x7f65fa2f1950 (LWP 16319)] [New Thread 0x7f65f5aef950 (LWP 16320)]

Program received signal SIGABRT, Aborted. 0x00007f660af54a15 in raise () from /lib64/libc.so.6 Missing debug package(s), you should install: OpenEXR-debug-1.6.1-3.1mdv2009.1.x86_64 bzip2-debug-1.0.5-5mdv2009.1.x86_64 dbus-debug-1.2.4.4permissive-2mdv2009.1.x86_64 fontconfig-debug-2.6.0-5mdv2009.1.x86_64 freetype2-debug-2.3.9-1.2mdv2009.1.x86_64 gamin-debug-0.1.10-2mdv2009.1.x86_64 gcc-debug-4.3.2-5mnb2.x86_64 gdbm-debug-1.8.3-10mdv2009.1.x86_64 glib2.0-debug-2.20.1-1.1mdv2009.1.x86_64 glibc-debug-2.9-0.20081113.5.1mnb2.x86_64 ilmbase-debug-1.0.1-6mdv2009.1.x86_64 jasper-debug-1.900.1-5.1mdv2009.1.x86_64 kde4-style-iaora-debug-0.2.3-1.2mdv2009.1.x86_64 kdebase4-runtime-debug-4.2.4-0.1mdv2009.1.x86_64 kdelibs4-debug-4.2.4-0.3mdv2009.1.x86_64 lcms-debug-1.18-1.1mdv2009.1.x86_64 libalsa2-debug-1.0.19-1mdv2009.1.x86_64 libcdio-debug-0.81-3mdv2009.1.x86_64 libice-debug-1.0.5-1mdv2009.1.x86_64 libjpeg-debug-6b-44mdv2009.1.x86_64 libmng-debug-1.0.10-9mdv2009.1.x86_64 libogg-debug-1.1.3-4mdv2009.1.x86_64 libpng-debug-1.2.35-1mdv2009.1.x86_64 libsm-debug-1.1.0-1mdv2009.1.x86_64 libtheora-debug-1.0-2mdv2009.1.x86_64 libtiff-debug-3.8.2-13.1mdv2009.1.x86_64 libvorbis-debug-1.2.0-5mdv2009.1.x86_64 libx11-debug-1.2.1-1.2mdv2009.1.x86_64 libxau-debug-1.0.4-1mdv2009.1.x86_64 libxcb-debug-1.2-1.2mdv2009.1.x86_64 libxcursor-debug-1.1.9-3mdv2009.1.x86_64 libxdmcp-debug-1.0.2-6mdv2009.1.x86_64 libxext-debug-1.0.5-2mdv2009.1.x86_64 libxfixes-debug-4.0.3-4mdv2009.1.x86_64 libxi-debug-1.2.1-1mdv2009.1.x86_64 libxinerama-debug-1.0.3-2mdv2009.1.x86_64 libxml2-debug-2.7.3-2.1mdv2009.1.x86_64 libxrandr-debug-1.3.0-1mdv2009.1.x86_64 libxrender-debug-0.9.4-4mdv2009.1.x86_64 libxtst-debug-1.0.3-3mdv2009.1.x86_64 pcre-debug-7.8-3mdv2009.1.x86_64 phonon-debug-4.3.1-11mdv2009.1.x86_64 pulseaudio-debug-0.9.15-2.0.6mdv2009.1.x86_64 qt4-debug-4.5.2-1.7mdv2009.1.x86_64 strigi-debug-0.6.4-2mdv2009.1.x86_64 tcp_wrappers-debug-7.6-39mdv2009.1.x86_64 vcdimager-debug-0.7.23-8mdv2009.1.x86_64 xine-lib-debug-1.1.16.3-1mdv2009.1.x86_64 xz-debug-4.999.8beta-0.2mdv2009.1.x86_64 zlib-debug-1.2.3-13mdv2009.1.x86_64 (gdb) where

0 0x00007f660af54a15 in raise () from /lib64/libc.so.6

1 0x00007f660af56243 in abort () from /lib64/libc.so.6

2 0x00007f660af959d0 in ?? () from /lib64/libc.so.6

3 0x0000000000447fa0 in ListeUtilisateurs::nouveauPj (this=0x262ee70,

checked=false) at src/ListeUtilisateurs.cpp:614

4 0x000000000047882d in ListeUtilisateurs::qt_metacall (this=0x262ee70,

_c=QMetaObject::InvokeMetaMethod, _id=4, _a=0x7fff5218ef20) at bin/moc_ListeUtilisateurs.cpp:92

5 0x00007f660b8fd472 in QMetaObject::activate () from /usr/lib64/libQtCore.so.4

6 0x00007f660c6a9897 in QAbstractButton::clicked () from /usr/lib64/libQtGui.so.4

7 0x00007f660c4037cb in ?? () from /usr/lib64/libQtGui.so.4

8 0x00007f660c405432 in ?? () from /usr/lib64/libQtGui.so.4

9 0x00007f660c405685 in QAbstractButton::mouseReleaseEvent () from

/usr/lib64/libQtGui.so.4

10 0x00007f660c0d9e0f in QWidget::event () from /usr/lib64/libQtGui.so.4

11 0x00007f660c088d1d in QApplicationPrivate::notify_helper () from

/usr/lib64/libQtGui.so.4

12 0x00007f660c09169c in QApplication::notify () from /usr/lib64/libQtGui.so.4

13 0x00007f660b8e7c9c in QCoreApplication::notifyInternal () from

/usr/lib64/libQtCore.so.4

14 0x00007f660c0908e8 in QApplicationPrivate::sendMouseEvent () from

/usr/lib64/libQtGui.so.4

15 0x00007f660c0fa869 in ?? () from /usr/lib64/libQtGui.so.4

16 0x00007f660c0f98a3 in QApplication::x11ProcessEvent () from /usr/lib64/libQtGui.so.4

17 0x00007f660c120f14 in ?? () from /usr/lib64/libQtGui.so.4

18 0x00007f6609a73e91 in g_main_context_dispatch () from /usr/lib64/libglib-2.0.so.0

19 0x00007f6609a77540 in ?? () from /usr/lib64/libglib-2.0.so.0

20 0x00007f6609a776dc in g_main_context_iteration () from /usr/lib64/libglib-2.0.so.0

21 0x00007f660b910fff in QEventDispatcherGlib::processEvents () from

/usr/lib64/libQtCore.so.4

22 0x00007f660c12069f in ?? () from /usr/lib64/libQtGui.so.4

23 0x00007f660b8e6532 in QEventLoop::processEvents () from /usr/lib64/libQtCore.so.4

24 0x00007f660b8e6904 in QEventLoop::exec () from /usr/lib64/libQtCore.so.4

25 0x00007f660b8e8bd4 in QCoreApplication::exec () from /usr/lib64/libQtCore.so.4

26 0x000000000044d488 in main (argc=1, argv=0x7fff52191838) at src/main.cpp:216

(gdb)

J'espère que ça vous aidera.

NOTE : dois-je installer les packages "*-debug" comme suggéré par gdb ?

Comment #3

Posted on Oct 7, 2009 by Swift Rhino

Re-bonjour,

J'ai finalement installé les packages *-debug suggérés par gdb. J'en ai profité également pour tester l'exécution de rolisteam avec valgrind, qui m'a fait ressortir la ligne 608 du fichier ListeUtilisateurs.cpp comme ayant un problème de taille mémoire.

Effectivement, une petite erreur semble s'être glissée dans le "sizeof()" du memcopy.

J'ai corrigé avec la bonne valeur, j'ai testé et ça fonctionne correctement maintenant. Ci-joint un fichier patch.

J'espère que j'ai trouvé la bonne correction ? Je ne m'y connais pas beaucoup en C++ ni en librairies QT mais j'apprends vite, donc si je peux vous aider à développer sur le logiciel, se sera avec plaisir.

Je peux faire des tests et du debug dans un premier temps, si vous le voulez :-)

Cordialement, Tristan

Attachments

Comment #4

Posted on Oct 8, 2009 by Happy Hippo

Ok ok, je regarderai ça. Pour être honnete tout ce code vient de rolistik, c'est assez spartiate. Je testerai ton patch (on se tutoie?). Je te contacterai sur ton adresse email.

Comment #5

Posted on Oct 8, 2009 by Swift Rhino

Oui oui, pas de soucis pour le tutoiement :) N'hésites pas à me contacter dès que tu le souhaites. Tristan.

Comment #6

Posted on May 30, 2010 by Happy Hippo

(No comment was entered for this change.)

Status: Fixed

Labels:
Type-Defect Priority-Medium