Fix some regexps in xfstests
authorDean Roehrich <roehrich@sgi.com>
Tue, 6 Jan 2004 18:44:26 +0000 (18:44 +0000)
committerDean Roehrich <roehrich@sgi.com>
Tue, 6 Jan 2004 18:44:26 +0000 (18:44 +0000)
Fix regexp for xvm devices

052
common.filter
common.quota

diff --git a/052 b/052
index d7d64416e70845ec738decb683ee242756c5d473..87a4a0dbdb53f51120be7129b147a0a60af3e214 100755 (executable)
--- a/052
+++ b/052
@@ -97,14 +97,14 @@ setquota -$type $id 1001 1001 10 10 $SCRATCH_DEV
 
 # cross check blks, softblks, hardblks <-> quota, xfs_db
 quota -$type $id | tee -a $seq.full | perl -ne '
-       if (m,^\s*'$SCRATCH_DEV'\s+(\d+)\s+(\d+)\s+(\d+), ||
+       if (m[^\s*'$SCRATCH_DEV'\s+(\d+)\s+(\d+)\s+(\d+)] ||
                ($next == 1 && m,^\s+(\d+)\s+(\d+)\s+(\d+),)) {
                print "used_blocks=", $1, "\n";
                print "soft_blocks=", $2, "\n";
                print "hard_blocks=", $3, "\n";
                $next = 0;
        }
-       elsif (m,^\s*'$SCRATCH_DEV',) {         # devfs (long) names
+       elsif (m[^\s*'$SCRATCH_DEV']) {         # devfs (long) names
                $next = 1;
        }' | LC_COLLATE=POSIX sort >$tmp.quota
 
index eff2d728e61bb36c77d2df322af4728e65359a51..2fef30331ec489e81686275cfbac66044637822a 100644 (file)
@@ -150,7 +150,7 @@ _filter_mkfs()
 {
     set -
     perl -ne '
-    if (/^meta-data=([\w|\/.-]+)\s+isize=(\d+)\s+agcount=(\d+), agsize=(\d+) blks/) {
+    if (/^meta-data=([\w,|\/.-]+)\s+isize=(\d+)\s+agcount=(\d+), agsize=(\d+) blks/) {
        print STDERR "ddev=$1\nisize=$2\nagcount=$3\nagsize=$4\n";
        print STDOUT "meta-data=DDEV isize=XXX agcount=N, agsize=XXX blks\n";
     }
index 5d6916133591422f61256980e95826e5cd8948f5..734dacd959ba5e30f65e49a236454cf71eeadd56 100644 (file)
@@ -90,7 +90,7 @@ _filter_repquota()
 {
     head -$1 | perl -ne "
        s/^(\w+)\s+([-|+])/[NAME]    \2/g;
-       s,$SCRATCH_DEV,[DEVICE],g;
+       s($SCRATCH_DEV)([DEVICE])g;
        print"
 }