do i have any memory leaks?
  
/* 
 * Print a user profile. 
 * For an example of the required output format, see the example output 
 * linked from the handout. 
 * Return: 
 *   - 0 on success. 
 *   - 1 if the user is NULL. 
 */  
int print_user(const User *user) {  
    // check if user is NULL  
    if (user == NULL) {  
        return 1;  
    }  
  
    // check if there is a profile pic associated with the user  
    if (strlen(user->profile_pic) != 0){  
        // open the profile pic  
        FILE *fptr;  
        fptr = fopen(user->profile_pic, "r");  
        if (fptr == NULL){  
            printf("Cannot open file \n");  
        }  
    
        // Read contents from file and print them   
        char pic = fgetc(fptr);  
        while (pic != EOF){  
            printf ("%c", pic);  
            pic = fgetc(fptr);  
        }  
    printf("\n");  
    }// print name  
    printf("Name: %s\n", user->name);  
    printf("------------------------------------------\n");  
  
    // print each friend in order in which they became friends  
    printf("Friends:\n");  
    for (int i = 0; i < MAX_FRIENDS; i++) {  
        User *friend = user->friends[i];  
        if (friend != NULL) {  
            printf("%s\n", friend->name);  
        }  
    }  
    printf("------------------------------------------\n");  
  
    printf("Posts:\n");  
    Post *current_post = user->first_post;  
    while (current_post != NULL) {  
        printf("From: %s\n", current_post->author);  
        // convert time_t to a string  
        printf("Date: %s", ctime(current_post->date));  
        // checks if post is the last to see if "===" is needed  
        if (current_post->next == NULL){  
            printf("\n%s\n", current_post->contents);  
        }  
        else {  
            printf("\n%s\n\n===\n\n", current_post->contents);  
        }  
        current_post = current_post->next;  
    }  
    printf("------------------------------------------\n");  
    return 0;  
}  
  