user2519862
user2519862

Reputation:

getting Error ksh[7]: test: argument expected

When executing the below line , am getting the error ksh[7]: test: argument expected

while [ $cont = "y" ]

Whats wrong with this line?

Upvotes: 1

Views: 16454

Answers (1)

dogbane
dogbane

Reputation: 274562

$cont might not be set, which is why it fails.

Enclose the variable in double quotes like this:

while [ "$cont" = "y" ]

Upvotes: 2

Related Questions