blob: 3bacea9c6f2df776bf8ad715f9d7b3cbcdd4745a [file] [log] [blame]
changeset: 340:510681ff43bf
user: Jef Poskanzer <jef@mail.acme.com>
date: Mon May 06 09:41:35 2013 -0700
summary: getopt_long returns int, not char.
diff -r 6e0c9c8e0bed -r 510681ff43bf src/iperf_api.c
--- a/src/iperf_api.c Thu May 02 15:28:30 2013 -0700
+++ b/src/iperf_api.c Mon May 06 09:41:35 2013 -0700
@@ -439,14 +439,14 @@
#endif
{NULL, 0, NULL, 0}
};
- char ch;
+ int flag;
int blksize;
int server_flag, client_flag;
blksize = 0;
server_flag = client_flag = 0;
- while ((ch = getopt_long(argc, argv, "p:f:i:DVJdvsc:ub:t:n:l:P:Rw:B:M:N6S:Zh", longopts, NULL)) != -1) {
- switch (ch) {
+ while ((flag = getopt_long(argc, argv, "p:f:i:DVJdvsc:ub:t:n:l:P:Rw:B:M:N6S:Zh", longopts, NULL)) != -1) {
+ switch (flag) {
case 'p':
test->server_port = atoi(optarg);
break;