Skip to contentSkip to conversation

Btrfs-progs: add correct indentation

PATCH In review Anand Jain 2 participants 3 messages Feb 22, 2013 – Feb 28, 2013 Btrfs file system

lore
Share & tools
lore

Anand Jain

author
#0 lore raw

PATCH 1/1 Btrfs-progs: add correct indentation

A trivial fix, corrects the indentation.

---
 utils.c | 13 +++++++------
 1 file changed, 7 insertions(+), 6 deletions(-)
utils.c +7 -6
index d660507..9c2e510 100644
@@ -1192,12 +1192,13 @@ scan_again:
 		return -ENOENT;
 	}
 	/* skip the header */
-	for(i=0; i < 2 ; i++)
-		if(!fgets(buf, 1023, proc_partitions)){
-		fprintf(stderr, "Unable to read '/proc/partitions' for scanning\n");
-		fclose(proc_partitions);
-		return -ENOENT;
-	}
+	for (i=0; i < 2 ; i++)
+		if (!fgets(buf, 1023, proc_partitions)) {
+			fprintf(stderr,
+				"Unable to read '/proc/partitions' for scanning\n");
+			fclose(proc_partitions);
+			return -ENOENT;
+		}
 
 	strcpy(fullpath,"/dev/");
 	while(fgets(buf, 1023, proc_partitions)) {
Signature · 1 line
1.8.1.227.g44fe835
#1 lore raw

utils.c scan_again: · line 1195

Quoted 13 lines · Anand Jain
utils.c +1 -6
@@ -1192,12 +1192,13 @@ scan_again:
 		return -ENOENT;
 	}
 	/* skip the header */
-	for(i=0; i < 2 ; i++)
-		if(!fgets(buf, 1023, proc_partitions)){
-		fprintf(stderr, "Unable to read '/proc/partitions' for scanning\n");
-		fclose(proc_partitions);
-		return -ENOENT;
-	}
+	for (i=0; i < 2 ; i++)
	for (i = 0; i < 2; i++)

If possible, It's good to fix these issues in one go, I'll fix it locally.

david

author
#2 lore raw
Quoted 17 lines · David Sterba

utils.c scan_again: · line 1195

Quoted 13 lines · Anand Jain
utils.c +1 -6
@@ -1192,12 +1192,13 @@ scan_again:
  		return -ENOENT;
  	}
  	/* skip the header */
-	for(i=0; i < 2 ; i++)
-		if(!fgets(buf, 1023, proc_partitions)){
-		fprintf(stderr, "Unable to read '/proc/partitions' for scanning\n");
-		fclose(proc_partitions);
-		return -ENOENT;
-	}
+	for (i=0; i < 2 ; i++)
	for (i = 0; i < 2; i++)
Quoted 1 line

If possible, It's good to fix these issues in one go, I'll fix it locally.

Absolutely. Sorry my mistake. A new patch below if it helps. Thanks

Anand