Memset

From Bennu Wiki
(Redirected from Mem set)
Jump to: navigation, search


Syntax

INT memset ( <VOID POINTER data> , <BYTE value> , <INT bytes> )

Description

Sets all bytes in the specified memory block to the specified value.

Also called mem_set().

Parameters

VOID POINTER data - Pointer to the block of bytes in memory
BYTE value - Value to set all bytes to.
INT bytes - Number of bytes to change the value of.

Returns

INT : true

Example

See alloc().

Also useful in conjunction with map_buffer() with 8bit maps. (Example can be found in the map_buffer article.)


Mod_mem
Functions Alloc()Calloc()Free()Memalloc()Memavailable()Memcalloc()Memcmp()Memcopy()Memfree()Memmove()Memrealloc()Memset()Memseti()Memsetw()Memtotal()Memcmp()Memcopy()Memmove()Memoryfree()Memorytotal()Memset()Memseti()Memsetw()Realloc()