fix: Emit error message for an unknown i_error, rather than an empty string. (#1030)

Suggested by @david-BarOn.

Towards #1022.
This commit is contained in:
Bruce A. Mah 2020-07-24 17:32:00 -07:00 committed by GitHub
parent 1a908ce13e
commit a9c28038c0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -424,6 +424,10 @@ iperf_strerror(int int_errno)
case IETOTALRATE:
snprintf(errstr, len, "total required bandwidth is larger than server limit");
break;
default:
snprintf(errstr, len, "int_errno=%d", int_errno);
perr = 1;
break;
}
/* Append the result of strerror() or gai_strerror() if appropriate */