uppercase fixed

This commit is contained in:
Simon 2025-10-25 17:50:41 +02:00
parent 30ef5e53f5
commit ad88cbbba6

View File

@ -29,14 +29,21 @@ int readWords(FILE *file, char words[][MAX_WORD_LEN], unsigned int maxWordCount)
while (token != NULL)
{
strncpy(words[n], token, MAX_WORD_LEN);
char *s = words[n];
while (*s)
{
*s = toupper((unsigned char)*s);
s++;
}
// printf("Einzelwort: %s\n", words[n]);
token = strtok(NULL, teiler);
n++;
}
}
fclose(file);
return 0;
return n;
}