Tweak callsign length warning

This commit is contained in:
Philip Heron 2023-03-04 13:10:40 +00:00
parent 69944cb29a
commit 998d843f51
1 changed files with 3 additions and 1 deletions

4
main.c
View File

@ -79,7 +79,9 @@ int main(int argc, char *argv[])
case 'n': type = SSDV_TYPE_NOFEC; break;
case 'c':
if(strlen(optarg) > 6)
fprintf(stderr, "Warning: callsign is longer than 6 characters.\n");
{
fprintf(stderr, "Warning: callsign cropped to 6 characters.\n");
}
strncpy(callsign, optarg, 6);
callsign[6] = '\0';
break;