Module Name:    src
Committed By:   kre
Date:           Sun Jan 19 00:57:00 UTC 2020

Modified Files:
        src/distrib/miniroot: install.sub

Log Message:
test ! -n "$foo"   is just a quaint way of saying test -z "$foo"
and test ! -z "$foo" is really just test -n "$foo"  so let's just
use the simple (and more obvious) forms.

NFCI.


To generate a diff of this commit:
cvs rdiff -u -r1.52 -r1.53 src/distrib/miniroot/install.sub

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/distrib/miniroot/install.sub
diff -u src/distrib/miniroot/install.sub:1.52 src/distrib/miniroot/install.sub:1.53
--- src/distrib/miniroot/install.sub:1.52	Sun Jan 19 00:50:25 2020
+++ src/distrib/miniroot/install.sub	Sun Jan 19 00:57:00 2020
@@ -1,5 +1,5 @@
 #!/bin/sh
-#	$NetBSD: install.sub,v 1.52 2020/01/19 00:50:25 kre Exp $
+#	$NetBSD: install.sub,v 1.53 2020/01/19 00:57:00 kre Exp $
 #
 # Copyright (c) 1996 The NetBSD Foundation, Inc.
 # All rights reserved.
@@ -523,7 +523,7 @@ if [ -f /mnt/etc/rc.conf ]; then
 		echo -n "configuring network interfaces:"
 		for i in $tmp; do
 			eval $(echo 'args=$ifconfig_'$i)
-			if [ ! -z "$args" ]; then
+			if [ -n "$args" ]; then
 				echo -n " $i"
 				ifconfig $i $args
 			elif [ -f /mnt/etc/ifconfig.$i ]; then
@@ -555,7 +555,7 @@ else
 			read af name mask bcaddr extras
 			read dt dtaddr
 
-			if [ ! -n "$name" ]; then
+			if [ -z "$name" ]; then
 		    echo "/etc/hostname.$1: invalid network configuration file"
 				exit
 			fi
@@ -1047,7 +1047,7 @@ The following filesystem types are suppo
 __mount_a_disk_2
 	_md_fstype=$(md_native_fstype)
 	_md_fsopts=$(md_native_fsopts)
-	if [ ! -z "$_md_fstype" ]; then
+	if [ -n "$_md_fstype" ]; then
 		echo "	3) $_md_fstype"
 	else
 		_md_fstype="_undefined_"

Reply via email to