int print_user(const User *user) {
    if (user == NULL){
            return 1;
    }
    FILE *profile_pic;
    if ((profile_pic = fopen(user->profile_pic, "r")) != NULL){
        int c;
          while ((c = getc(profile_pic)) != EOF){
            printf("%c", c);
          }
        fclose(profile_pic);
    }
    printf("\n");
    printf("Name: %s\n", user->name);
    printf("------------------------------------------\n");
    printf("Friends:\n");
    int i = 0;
    while(user->friends[i] != NULL){
        printf("%s\n", user->friends[i]->name);
        i++;
    }
    printf("------------------------------------------\n");
    printf("Posts:\n");
    Post *temp = user->first_post;
    while(user->first_post != NULL){
            printf("From: %s\n", user->first_post->author);
            printf("Date: %s\n", user->first_post->date);
            printf("\n");
            printf("%s\n", user->first_post->contents);
            user->first_post = user->first_post->next;
    }
    user->first_post = temp;
    printf("------------------------------------------\n");
    return 0;
}

Error in assigning first_post