Allocation qui plante qu'en release.

Résolu
moumouteb Messages postés 192 Date d'inscription dimanche 16 janvier 2005 Statut Membre Dernière intervention 28 février 2011 - 6 déc. 2006 à 18:59
moumouteb Messages postés 192 Date d'inscription dimanche 16 janvier 2005 Statut Membre Dernière intervention 28 février 2011 - 7 déc. 2006 à 22:12
Bonjour.

J'utilise une librairie toute faite (guichan) tout marche bien lors de la déclaration du gui enfin tant que je compile en mode debug. Lors que je compile en mode release la déclaration dynamique du gui :
gui = new gcn::Gui();
provoque une erreur à l'exécution:
Exception non gérée à 0x7c812a5b dans sc2.exe : Exception Microsoft C++ : std::bad_alloc à l'emplacement mémoire 0x0012fcc0..
Pourquoi cela n'arrive que lorsque je compile en version release et d'ou cela peut venir?

La définition de Gui()
[file:///C:/Documents%20and%20Settings/mouteb/Mes%20documents/programmation/jeux/gui/guichan-0.5.0-src/guichan-0.5.0-src/docs/html/classgcn_1_1Gui.html#da0ae56b26099a1bbb70fc4bb8d77da1 Gui::Gui]()
[file:///C:/Documents%20and%20Settings/mouteb/Mes%20documents/programmation/jeux/gui/guichan-0.5.0-src/guichan-0.5.0-src/docs/html/classgcn_1_1Gui.html#604a47aac29b2b2d102fb9adf33046dd mTop] = NULL;
[file:///C:/Documents%20and%20Settings/mouteb/Mes%20documents/programmation/jeux/gui/guichan-0.5.0-src/guichan-0.5.0-src/docs/html/classgcn_1_1Gui.html#3a5628dce778c217e817b40e552c1dd4 mInput] = NULL;
[file:///C:/Documents%20and%20Settings/mouteb/Mes%20documents/programmation/jeux/gui/guichan-0.5.0-src/guichan-0.5.0-src/docs/html/classgcn_1_1Gui.html#bf24a26828a0714cb5b35874f1aeb2aa mGraphics] = NULL;
[file:///C:/Documents%20and%20Settings/mouteb/Mes%20documents/programmation/jeux/gui/guichan-0.5.0-src/guichan-0.5.0-src/docs/html/classgcn_1_1Gui.html#6d52184d92b5fb94c9e431310e822bb9 mFocusHandler] = new[file:///C:/Documents%20and%20Settings/mouteb/Mes%20documents/programmation/jeux/gui/guichan-0.5.0-src/guichan-0.5.0-src/docs/html/classgcn_1_1FocusHandler.html FocusHandler]();
[file:///C:/Documents%20and%20Settings/mouteb/Mes%20documents/programmation/jeux/gui/guichan-0.5.0-src/guichan-0.5.0-src/docs/html/classgcn_1_1Gui.html#23d7cb3158ea0c5adb81ea2b7925d6a2 mTopHasMouse] = false;
[file:///C:/Documents%20and%20Settings/mouteb/Mes%20documents/programmation/jeux/gui/guichan-0.5.0-src/guichan-0.5.0-src/docs/html/classgcn_1_1Gui.html#1cb20f54584e46d504fabaeca4937991 mTabbing] = true;
[file:///C:/Documents%20and%20Settings/mouteb/Mes%20documents/programmation/jeux/gui/guichan-0.5.0-src/guichan-0.5.0-src/docs/html/classgcn_1_1FocusHandler.html#41eeb97436bdf9931d4d3207f451f749 FocusHandler::FocusHandler]()
[file:///C:/Documents%20and%20Settings/mouteb/Mes%20documents/programmation/jeux/gui/guichan-0.5.0-src/guichan-0.5.0-src/docs/html/classgcn_1_1FocusHandler.html#e5a9d82ff3e401ee77a06e2f5b980931 mFocusedWidget] = NULL;
[file:///C:/Documents%20and%20Settings/mouteb/Mes%20documents/programmation/jeux/gui/guichan-0.5.0-src/guichan-0.5.0-src/docs/html/classgcn_1_1FocusHandler.html#2ba902b2089e045d673e92d58feacaea mDraggedWidget] = NULL;
[file:///C:/Documents%20and%20Settings/mouteb/Mes%20documents/programmation/jeux/gui/guichan-0.5.0-src/guichan-0.5.0-src/docs/html/classgcn_1_1FocusHandler.html#98bb8427d5a7c93ba3a0f28a7fdc1c7b mToBeFocused] = NULL;
[file:///C:/Documents%20and%20Settings/mouteb/Mes%20documents/programmation/jeux/gui/guichan-0.5.0-src/guichan-0.5.0-src/docs/html/classgcn_1_1FocusHandler.html#56ad83a3cacf4889280c662a080adbb5 mToBeDragged] = NULL;
[file:///C:/Documents%20and%20Settings/mouteb/Mes%20documents/programmation/jeux/gui/guichan-0.5.0-src/guichan-0.5.0-src/docs/html/classgcn_1_1FocusHandler.html#1c77d27feb506c048e0732fa29375599 mModalFocusedWidget] = NULL;
Squirrel's Cliff

1 réponse

moumouteb Messages postés 192 Date d'inscription dimanche 16 janvier 2005 Statut Membre Dernière intervention 28 février 2011 10
7 déc. 2006 à 22:12
J'ai fini par trouver la solution qui venait de la compilation de la librairie guichan. Au cas ou quelqu'un ai le même problème la solution est ici .

<hr size="2" width="100%" />Quand la merde vaudra de l'or les pauvres naitrons sans trou du cul. Coluche.
Mon projet : Squirrel's Cliff
3
Rejoignez-nous