Anybody know what the fastest way to clear a buffer in C on Linux would be? Anything faster than

for(i = 0; i < sizeofbuffer; i++)
        buffer[i] = 0;

?

For some reason I think I saw

memcpy(&buffer, 0, sizeofbuffer);

used somewhere once, but after a long day, that looks wierd to me.

-Charles

Reply via email to