From: ace j. <ac...@ho...> - 2006-05-12 02:28:09
|
Hi, Tom. Thanks for the patch! Yes, these have been fixed in the CVS version. I should probably release another rev. Please direct future inquiries at the mailing list (cc'd). Most of the mail sent directly to me is spam, so it's too easy to miss mails like this one that are actually relevant. Best, </Ace> On Fri, 2006-04-28 at 13:27, LeRoux, Tom wrote: > Hello.. had some seg faults using my Dell DJ with 0.2.4 version of > kionjb... looks like I was getting a null frame back from "frame = > NJB_Songid_Findframe( song, FR_LENGTH);" I put a couple null checks > around the gets for song size and song length which seemed to fix the > problem. Maybe you've fixed this already.. but sourceforge CVS is > down so I can't check.. anyway, here's a patch: > > > *** kionjb-0.2.4-orig/kionjb/track.cpp Mon Jul 4 20:25:09 2005 > --- kionjb-0.2.4/kionjb/track.cpp Fri Apr 28 16:22:28 2006 > *************** > *** 73,79 **** > > frame = NJB_Songid_Findframe( song, FR_SIZE); > // kdDebug( 7182) << "frame = NJB_Songid_Findframe( song, > FR_SIZE);" << endl; > ! if ( frame->type == NJB_TYPE_UINT32 ) > size = frame->data.u_int32_val; > else > { > --- 73,81 ---- > > frame = NJB_Songid_Findframe( song, FR_SIZE); > // kdDebug( 7182) << "frame = NJB_Songid_Findframe( song, > FR_SIZE);" << endl; > ! if ( !frame ) { > ! size = 0; > ! } else if ( frame->type == NJB_TYPE_UINT32 ) > size = frame->data.u_int32_val; > else > { > *************** > *** 83,89 **** > > frame = NJB_Songid_Findframe( song, FR_LENGTH); > //kdDebug( 7182) << "frame = NJB_Songid_Findframe( song, > FR_LENGTH);" << endl; > ! if ( frame->type == NJB_TYPE_UINT16 ) > duration = frame->data.u_int16_val; > else > { > --- 85,93 ---- > > frame = NJB_Songid_Findframe( song, FR_LENGTH); > //kdDebug( 7182) << "frame = NJB_Songid_Findframe( song, > FR_LENGTH);" << endl; > ! if ( !frame ) { > ! duration = 0; > ! } else if ( frame->type == NJB_TYPE_UINT16 ) > duration = frame->data.u_int16_val; > else > { > > > -- > Tom LeRoux > Goldman Sachs > 917-343-5272 > tom...@gs... > -- Ace Jones <ac...@ho...> GPG Public Key on www.keyserver.net Fingerprint: 3CA8 1A24 B52F 4FCA C22D 0E2F 0AF0 4EE1 F540 E55B |