Fix attempting to pass by reference in C