gnomecard problems




There are some problems with the latest gnomecard.  The first one I can
reproduce easily.  When you first run the application and then go to
preferences and then change the order of items displayed, it will core
dump because there are no items to reorder.  Looks like it's trying to
reorder without checking to see if there are actually anything in the card
data structure.

The second one core dumps when you try to save a file.  It's referencing a
NULL pointer because when it tries to do an fopen in line 222 in
gnomecard.c (gnomecard_save() I think), it fails to open it because there
is no default filename.  I think if a default filename is given things
should be fixed.  I haven't had a chance to fix it as of yet.  Currently,
it's using "" as a filename.  Probably not right. :-)

It's generally good practice especially in WiP (work in progress) software
to capture all return values from system calls (like fopen).  You should
always check to see if you are about to deference a NULL pointer.  Worked
for me anyways. :-)
	
	sri

---------------------------------------------------------------------------
Sri Ramkrishna         /|\ Unix is very user friendly, its just very picky
email: sri@aracnet.com -|- on who it is friendly to. -- Unknown? 
phone: 503-645-4868    \|/ 
---------------------------------------------------------------------------
                        |





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]