xnee-devel
[Top][All Lists]
Advanced

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

Re: [Xnee-devel] Bug in libxnee/src/xnee.c


From: Henrik Sandklef
Subject: Re: [Xnee-devel] Bug in libxnee/src/xnee.c
Date: Tue, 25 Jan 2005 10:40:12 +0100 (CET)
User-agent: SquirrelMail/1.4.3a

Hi, and thanks for your note!

What to return depends on what you want to achieve! I may get the Nobel
prize for that conclusion ;)

1) If you want Xnee to stop recording when any of the following is true
   event conunter is zero
   data counter is zero
   time has elapsed
then, continue if  (evs!=0) && (dats!=0) && (tims!=0)

2) If you want Xnee to stop recording when all of the following is true
   event conunter is zero
   data counter is zero
   time has elapsed
then, continue if  (evs!=0) || (dats!=0) || (tims!=0)



What is choosen in Xnee is the first (1). When enever one counter has
reached zero (to tell the truth time is not used!) Xnee quits recording.

Do you think that this is the wrong behaviour?

There is a fresh version here:
   http://www.sandklef.com/xnee/Xnee-1.08.95/Xnee-1.08.95a.tar.gz


/hesa




> So, I am looking at the following code in
> Xnee-1.08.94p/libxnee/src/xnee.c. Should the return value not be
>
>   return (int) ( (evs!=0) || (dats!=0) || (tims!=0) );
>
> int xnee_more_to_record(xnee_data *xd)
>
> {
>   int evs;
>   int dats;
>   int tims;
>
>   evs = xnee_get_events_left(xd);
>   if (evs<0) evs = 1;
>
>   dats = xnee_get_data_left(xd);
>   if (dats<0) dats = 1;
>
>   tims = xnee_get_time_left(xd);
>   if (tims<0) tims = 1;
>
>   return (int) ( (evs!=0) && (dats!=0) && (tims!=0) );
>
> }
>
>
> Niraj
>
> --
> http://www.cs.cmu.edu/~ntolia
>
>
> _______________________________________________
> Xnee-devel mailing list
> address@hidden
> http://lists.gnu.org/mailman/listinfo/xnee-devel
>


-- 
--- www.gnu.org -----
  ,           ,
 /             \
((__-^^-,-^^-__))
 `-_---' `---_-'
  `--|o` 'o|--'
     \  `  /
      ): :(
      :o_o:
       "-"






reply via email to

[Prev in Thread] Current Thread [Next in Thread]