Skip to contentSkip to conversation

xfsqa 185 - remove uninitialised variables in golden output.

PATCH In review David Chinner 2 participants 3 messages Apr 8, 2008

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 xfsqa 185 - remove uninitialised variables in golden output.

Kill the output of uninitialised values when punching a hole. This prevents the test from passing on just about everything.

---
 xfstests/185.out                                        |    5 -----
 xfstests/dmapi/src/suite1/cmd/probe_punch_xfsctl_hole.c |    2 +-
 2 files changed, 1 insertion(+), 6 deletions(-)
xfstests/185.out +0 -5
Index: xfs-cmds/xfstests/185.out
===================================================================
@@ -12,7 +12,6 @@ roffp is 0, rlenp is 16384
 Method:	dmapi_punch
 Running DMAPI punch hole on /mnt/scratch/dmapi/holly_file with settings:
   offset = '0', length = '16384', sid = '0'
-roffp is 4200149, rlenp is 47820330485640
 =======================================================
 =======================================================
 Testing with length = 1k, offset = 0
@@ -27,7 +26,6 @@ roffp is 0, rlenp is 1024
 Method:	dmapi_punch
 Running DMAPI punch hole on /mnt/scratch/dmapi/holly_file with settings:
   offset = '0', length = '1024', sid = '0'
-roffp is 4200149, rlenp is 47194545715080
 =======================================================
 =======================================================
 Testing with length = 1k, offset = 4k
@@ -42,7 +40,6 @@ roffp is 4096, rlenp is 1024
 Method:	dmapi_punch
 Running DMAPI punch hole on /mnt/scratch/dmapi/holly_file with settings:
   offset = '4096', length = '1024', sid = '0'
-roffp is 4200149, rlenp is 47256598480776
 =======================================================
 =======================================================
 Testing with length = 4k, offset = 1k
@@ -57,7 +54,6 @@ roffp is 1024, rlenp is 4096
 Method:	dmapi_punch
 Running DMAPI punch hole on /mnt/scratch/dmapi/holly_file with settings:
   offset = '1024', length = '4096', sid = '0'
-roffp is 4200149, rlenp is 47292581427080
 =======================================================
 =======================================================
 Testing with length = 1024k, offset = 512k
@@ -72,5 +68,4 @@ roffp is 524288, rlenp is 1048576
 Method:	dmapi_punch
 Running DMAPI punch hole on /mnt/scratch/dmapi/holly_file with settings:
   offset = '524288', length = '1048576', sid = '0'
-roffp is 4200149, rlenp is 47016592795528
 =======================================================
xfstests/dmapi/src/suite1/cmd/probe_punch_xfsctl_hole.c +1 -1
Index: xfs-cmds/xfstests/dmapi/src/suite1/cmd/probe_punch_xfsctl_hole.c
===================================================================
@@ -176,6 +176,7 @@ main(
 				strerror(errno));
 			exit(1);
 		}
+		fprintf(stdout, "roffp is %lld, rlenp is %lld\n", roffp, rlenp);
 		break;
 	case METHOD_DMAPI_PUNCH:
 		if (dm_punch_hole(sid, hanp, hlen, DM_NO_TOKEN, offset, length)) {
@@ -185,7 +186,6 @@ main(
 		}
 		break;			
 	}
-	fprintf(stdout, "roffp is %lld, rlenp is %lld\n", roffp, rlenp);
 	dm_handle_free(hanp, hlen);
 	
 	return 0;
#1 lore raw
Quoted 4 lines · David Chinner

Kill the output of uninitialised values when punching a hole. This prevents the test from passing on just about everything.

Thanks dave, I've been meaning to do that for a long time, we might want to kill the sid output too when it's not specified on command line (can that change ? I've always seen it as 0).

Cheers,

Signature · 1 line
Niv Sardi
#2 lore raw
Quoted 10 lines · Niv Sardi
Quoted 4 lines · David Chinner

Kill the output of uninitialised values when punching a hole. This prevents the test from passing on just about everything.

Thanks dave, I've been meaning to do that for a long time, we might want to kill the sid output too when it's not specified on command line (can that change ? I've always seen it as 0).

no idea. You can remove it as a separate patch if it is a problem. I'm going to check this one in now ;)

Cheers,

Dave.

Signature · 3 lines
Dave Chinner
Principal Engineer
SGI Australian Software Group