is there anything else i should free?
int make_post(const User *author, User *target, char *contents) {

    if (author == NULL | target == NULL) {
        return 2;
    }
    if (!(is_friends(author, target))) {
        return 1;
    }

    Post *new_post = malloc(sizeof(Post));
    if (new_post == NULL) {
        perror("malloc");  // Look up the documentation for perror
        return 2;
    }

    strcpy(new_post->author, author->name);
    new_post->contents = contents;

    new_post->date = malloc(sizeof(time_t));
    if (new_post->date == NULL) {
        perror("malloc");  // Look up the documentation for perror
        return 2;
    }

    *(new_post->date) = time(NULL);

    new_post->next = target->first_post;
    target->first_post = new_post;
    target->first_post->date = (new_post->date);

    free(new_post->date);
    free(new_post);
    return 0;
}