summaryrefslogtreecommitdiffstats
path: root/package/admswconfig/patches/001-matrix.patch
blob: e50d51575785be7988ab7f01b08a93bb752eb0fd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
--- a/admswconfig.c
+++ b/admswconfig.c
@@ -111,9 +111,9 @@ int main(int argc, char **argv)
 		}
 	} else {
 		/* display matrix */
-		printf("ethX\tport0\tport1\tport2\tport3\tport4");
-		if (info.ports == 6)
-			printf("\tport5");
+		printf("ethX");
+		for (i = 0; i < info.ports; i++)
+			printf("\tport%d", i);
 		printf("\tCPU\n");
 		for (i = 0; i < info.ports; i++) {
 			printf("%d", i);