thema is just a pointer - a piece of memory large enough to hold another memory address, there is not actually any space allocated for any struct messages data types, yet. You need to do this. Say you want N of these. Then you can do,
Also note that in C array indexes start at zero. So the elements of staticTopics are [0]-[5].Code:staticTopics[i].thema = malloc(N * sizeof(struct messages));
Good luck