void cowfill( unsigned char *buffer, size_t length ) { unsigned char *ptr = buffer + length - 1; if ( ! length ) { return; } switch ( length % 4 ) { while ( ptr >= buffer ) { case 0: *ptr-- = 0xEF; case 3: *ptr-- = 0xBE; case 2: *ptr-- = 0xAD; case 1: *ptr-- = 0xDE; } } }