Writing to array of structs inside an array of structs - C

I am writing a multi-threaded, client-server chat room program that allows for multiple private chatrooms. Most of the code works but I cannot seem to figure out why I cannot write to users present in the private chat rooms. The idea is to write out to an array of structs that each also contain another array of structs. I feel like I am making a simple mistake but im out of ideas. Below are snippets of code that I think represent the problem. I dont get seg faults or anything, just nothing happens. Any ideas?

typedef struct chat_user
{
   char *username;
   const char *color;
   int user_sd; 
   int in_room; 

} *chat_user;


typedef struct chat_room
{
   char *room_name;
   int creator_sd; 
   chat_user users_in_room[20];
   int users_in_room_size;

} *chat_room;




chat_room   arr_chat_room[20]; 
int total_rooms = 0;




void room_message(chat_user user, char *buffer, char *message)
{
   for(int i = 0; i < total_rooms; i++)
   {
      for (int j = 0; j < arr_chat_room[i]->users_in_room_size; j++)
      {
         write(arr_chat_room[i]->users_in_room[j]->user_sd,buffer,sprintf(buffer,"%s%s: %s",
        user->color,user->username,message,RESET));  

      }                  
   }  
}