Jim Cromie wrote:
 > Gilles Chanteperdrix wrote:
 > >
 > > You likely have a division by 0 because nsamples is 0. nsamples come
 > > from the numeric argument of the -n option, and I think you do not pass
 > > a numeric argument to -n, so atoi returns 0.
 > >
 > >   
 > 
 > Yup, thats it.
 > 
 > prog was getting -n -l 1000
 > -l is illegal option, but -n needs an arg, and -l became it, and 
 > converts to 0.
 > so no error caused by -l either !
 > 
 > attached patch does:

Applied, thanks.

 > 
 > xeno-test:     drop most options passed to switchbench,, added -h
 > switchbench:
 >     - sanity check on nsamples.
 >     - 1st column labels on Histogram
 >     - compute statistics (sort of -  I couldnt get 'sqrt' to link..)

sqrt is a math function, which requires linking with -lm. It is
fixed in the repository.

-- 


                                            Gilles Chanteperdrix.

_______________________________________________
Xenomai-core mailing list
Xenomai-core@gna.org
https://mail.gna.org/listinfo/xenomai-core

Reply via email to