From owner-freebsd-hackers Thu Apr 20 03:26:30 1995 Return-Path: hackers-owner Received: (from majordom@localhost) by freefall.cdrom.com (8.6.10/8.6.6) id DAA25134 for hackers-outgoing; Thu, 20 Apr 1995 03:26:30 -0700 Received: from inet-gw-1.pa.dec.com (inet-gw-1.pa.dec.com [16.1.0.22]) by freefall.cdrom.com (8.6.10/8.6.6) with SMTP id DAA25128 for ; Thu, 20 Apr 1995 03:26:28 -0700 Received: from rks32.pcs.dec.com by inet-gw-1.pa.dec.com (5.65/24Feb95) id AA18080; Thu, 20 Apr 95 03:24:30 -0700 Received: by rks32.pcs.dec.com (Smail3.1.27.1 #16) id m0s1tMY-0005PIC; Thu, 20 Apr 95 12:21 MSZ Message-Id: To: hackers%freebsd.org@inet-gw-1.pa.dec.com Subject: Re: CDROM stuff Reply-To: gj@FreeBSD.org Date: Thu, 20 Apr 95 10:21:29 GMT From: "gj%pcs.dec.com@inet-gw-1.pa.dec.com" Sender: hackers-owner@FreeBSD.org Precedence: bulk Some time ago there was discussion about xcdplayer and its bad habit of nattering at you when you change a CD, vis: >> I recently purchased a Chinon CDS-525 from Rodney Grimes, and I've been >>trying to get xcdplayer-2.2 (the one in the packages directory) going. I was >>wondering if anyone has problems with this. It seems to play just fine and >>all, but when I hit the eject button, it spews out >> >>open : Device not configured >> >>until I pop the cd back in again and the cdrom drive tells the program there's >>one there... anyone know what I should do to fix this? Thanks! >> > >This is a genereral problem with xcdplayer. Go make a patch for it and >I'd be happy to commit it to the tree. :) > >> >> >> >>-matt >> >>-- >>Matthew C. Mead -> Virginia Tech Center for Transportation Research - >> -> Multiple Platform System and Network Administration >>Work Related -> mmead@ctr.vt.edu | mmead@goof.com <- All Other >>---- ------- WWW -> http://www.goof.com/~mmead --- ----- > >-- >Justin T. Gibbs OK Justin, here's a patch which at least partially relieves the problem :) *** internals.c Tue Dec 29 11:56:08 1992 --- internals.c.fix Thu Apr 20 12:12:24 1995 *************** *** 605,611 **** } /* Reset timer */ ! stativid = XtAppAddTimeOut(appc, 1000, update_status, NULL); } /* --- 605,615 ---- } /* Reset timer */ ! /* give the user time to change the CD if one was ejected (60 sec.) */ ! if (cdi.state & CDROM_STATE_EJECTED) { ! stativid = XtAppAddTimeOut(appc, 60000, update_status, NULL); ! else ! stativid = XtAppAddTimeOut(appc, 1000, update_status, NULL); } /* Seems to me that 60 seconds should be long enough (works for me). One problem with this patch is that xcdplayer doesn't notice that there's a new CD in the drive until the timeout happens. But this is easy to get around, just click on the play button. Gary J.