Re: [PATCH 4/4] selftests: ftrace: Output only to console with "--logdir -"

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

 



On Wed, 5 Jul 2017 12:29:17 -0400
Steven Rostedt <rostedt@xxxxxxxxxxx> wrote:

> On Wed, 5 Jul 2017 12:25:06 -0400
> Steven Rostedt <rostedt@xxxxxxxxxxx> wrote:
> 
>  
> > > @@ -255,12 +262,18 @@ __run_test() { # testfile
> > >  # Run one test case
> > >  run_test() { # testfile
> > >    local testname=`basename $1`
> > > -  local testlog=`mktemp $LOG_DIR/${testname}-log.XXXXXX`
> > > +  if [ "$LOG_FILE" ] ; then  
> > 
> > Shouldn't this be
> > 
> > 	if [ ! -z "$LOG_FILE" ]; then
> > 
> > ?
> > 
> 
> OK, I just checked it out. I guess "" is considered zero and
> "<anything>" is considered 1.
> 
> Hmm, do we do this in other places too. Just makes me unconfortable.

OK, in that case, I can cleanup the code with [ ! -z "$VAR" ]

Thank you,

> 
> -- Steve
> 


-- 
Masami Hiramatsu <mhiramat@xxxxxxxxxx>
--
To unsubscribe from this list: send the line "unsubscribe linux-kselftest" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]

  Powered by Linux