3 ms·
while getc != EOF really? You stat the file for its size, then alloc the buffer with that size and fread into that. Or fseek the end and get the size via ftell
by rurban 2y ago
while getc != EOF really? You stat the file for its size, then alloc the buffer with that size and fread into that. Or fseek the end and get the size via ftell and fseek to the front
- int_19h 2y agoWhat problem are you trying to solve, exactly?