Tracker: Patches

5 Bug fixes for network/tcp_cmds/finger/finger01 - ID: 788275
Last Update: Settings changed ( robbiew )

When I ran the network tests, I got the following error:

/usr/local/ltp/testcases/bin/finger01: [: -ne: unary
operator expected

After poking around in finger01, I found the following:

FINGER=`netstat -a | grep "*:finger" |awk '{print $6}'`
if [ $FINGER -ne "LISTEN" ]; then

If the finger service isn't running, the FINGER
variable will have a value of nothing, so the if
statement will expand to:

if [ -ne "LISTEN" ]; then

When I fixed that error, I got another error on the
same line:

/usr/local/ltp/testcases/bin/finger01: [: LISTEN:
integer expression expected

"-ne" is for integer expressions, "!=" is for string
expressions.

The attached patch fixes two instances of these errors
in finger01.


David Smith ( drsmith2 ) - 2003-08-13 12:32:27 PDT

5

Deleted

Fixed

Robert Williamson

Testcases

TCP Commands

Public


Comment ( 1 )




Date: 2003-08-13 12:51:23 PDT
Sender: robbiewProject Admin

Logged In: YES
user_id=236704

Applied the patch to the CVS tree. Thanks!


Log in to comment.

Attached File ( 1 )

Filename Description Download
patch finger01 patch Download

Changes ( 6 )

Field Old Value Date By
status_id Closed 2005-02-07 11:41:24 PST robbiew
status_id Open 2003-08-13 12:51:23 PDT robbiew
resolution_id None 2003-08-13 12:51:23 PDT robbiew
close_date - 2003-08-13 12:51:23 PDT robbiew
assigned_to nobody 2003-08-13 12:48:44 PDT robbiew
File Added 58651: patch 2003-08-13 12:32:27 PDT drsmith2