Re:Begginer in C. Critique my code and give ideas?
by plikan13 on Friday January 30, 2015 @08:22AM
(#8971827)
sizeof(buffer) will always be 4 (or 8 if you compile 64 bit) because sizeof(pointer to char) is 4 (or 8). It will NOT be the size of the buffer that you pass as an argument. To fix this problem you need to change the function to
Also the buffers that you pass to this function seem to be too small.
[ Parent
| on HN ]