[Super-tux-devel] bug in cvs code
Brought to you by:
wkendrick
From: Arkadiusz M. <ar...@pl...> - 2004-04-25 00:19:08
|
Hi, Bug: lispreader.cpp: lisp_read_from_file() tries to open file and return FILE=20 handle but if it fails to open it doesn't exit with error and just pasess=20 NULL to calling functions. Now we have SpriteManager::load_resfile(const std::string& filename) { lisp_object_t* cur =3D lisp_read_from_file(filename); if (strcmp(lisp_symbol(lisp_car(cur)), "supertux-resources") !=3D 0) return; cur =3D lisp_cdr(cur); and nice segfault at lisp_car() since cur can be NULL. =2D-=20 Arkadiusz Mi=B6kiewicz CS at FoE, Wroclaw University of Technology arekm.pld-linux.org, 1024/3DB19BBD, JID: arekm.jabber.org, PLD/Linux |