[sheepdog] [PATCH] tests/functional: use a new variable RANDOM_GEN for _urandom()

Hitoshi Mitake mitake.hitoshi at gmail.com
Wed Jan 15 10:12:42 CET 2014


At Tue, 14 Jan 2014 11:05:10 +0900,
Hitoshi Mitake wrote:
> 
> At Sun, 12 Jan 2014 19:59:51 +0900,
> Hitoshi Mitake wrote:
> > 
> > On my ubuntu box (13.04), the openssl command called by _urandom()
> > dies with segmentation fault (yes, the walkaround was implemented in
> > the past but the problem occurs again...). For avoiding this problem,
> > this patch lets _urandom() use a new variable RANDOM_GEN. If this
> > variable is set, the function uses the variable as a command for
> > random number generation.
> > 
> > Signed-off-by: Hitoshi Mitake <mitake.hitoshi at lab.ntt.co.jp>
> > ---
> >  tests/functional/common.rc | 5 +++++
> >  1 file changed, 5 insertions(+)
> 
> ping?

ping?

> 
> > 
> > diff --git a/tests/functional/common.rc b/tests/functional/common.rc
> > index 3785bae..d9a3f50 100644
> > --- a/tests/functional/common.rc
> > +++ b/tests/functional/common.rc
> > @@ -486,7 +486,12 @@ _cluster_format()
> >  
> >  _random()
> >  {
> > +    if [ -z "$RANDOM_GEN" ];
> > +    then
> >  	openssl enc -rc4 -pass pass:"$(date)" -nosalt < /dev/zero 2>/dev/null
> > +    else
> > +	$RANDOM_GEN < /dev/zero 2> /dev/null
> > +    fi
> >  }
> >  
> >  _one()
> > -- 
> > 1.8.1.2
> > 



More information about the sheepdog mailing list