I've managed to complete recover however I want to understand the following segemntation fault issues:
1) Why if i use char * for a string for the filename variable it comes with an error? If i use an actual array of chars it's fine.
2) Why can't you use any file pointer based function in an else statement? If i use an IF statement it's fine but else throws a seg fault.
3) I used BYTE * and malloc for my buffer but I know others used an array of BYTE types for a buffer. Which is better methodology?