memset()                 Initialize Buffer
 
 #include   <memory.h>                   Required for declarations only
 #include   <string.h>                   Use either string.h or memory.h
 
 char       *memset(dest,ch,cnt);
 char       *dest;                       Pointer to destination
 int        ch;                          Character to set
 unsigned   cnt;                         Number of characters
 
    memset() sets the first 'cnt' bytes of the buffer 'dest' to the
    character 'ch'.
 
    Returns:    A pointer to the beginning of 'dest'.
 
  -------------------------------- Example ---------------------------------
 
    The following statement initializes the buffer 'buff' to 0.
 
         #include <memory.h>
 
         char buff[128];
 
         main()
         {
             memset(char,'\0',128);
         }

Seealso:



This page last updated on Fri Nov 30 10:48:32 MSK 2001
Copyright © 1992-2001, Vitaly Filatov, Moscow, Russia
Webmaster