examples/gnrc_tftp: avoid to print NULL

pr/rotary
kYc0o 7 years ago
parent 9ee1e1f156
commit bd81e010f8

@ -118,7 +118,12 @@ static void _tftp_client_stop_cb(tftp_event_t event, const char *msg)
}
/* print the transfer result to the console */
printf("tftp_client: %s: %s\n", cause, msg);
if (msg != NULL) {
printf("tftp_client: %s: %s\n", cause, msg);
}
else {
printf("tftp_client: %s\n", cause);
}
}
static int _tftp_client_cmd(int argc, char * *argv)

Loading…
Cancel
Save