Happy new year.
It's too late to deep check your code, but as first point the following is uncorrect:
stop_words = calloc(1, sizeof(wchar_t));
It should be:
stop_words = calloc(1, sizeof(wchar_t *));
And also:
stop_words = realloc(stop_words, i);
Should be:
stop_words = realloc(stop_words, i * sizeof(wchar_t *));
The debugger is your friend, use it.