| iMatix home page
| << | < | > | >>
SFL Logo SFL
Version 2.11

 

mem_check_

#include "sflmem.h"
void
mem_check_ (
    const void *client_ptr,             /*  Block of memory to free          */
    const char *filename,               /*  Name of source file making call  */
    size_t      lineno                  /*  Line number in calling source    */
)

Synopsis

Checks that a block of memory has not been corrupted. If the block is corrupted, aborts with an error message, else does nothing.

Source Code - (sflmem.c)

{
    MEMHDR
       *ptr;

    if (client_ptr == NULL)             /*  Do nothing if address is null    */
        return;

    /*  Check for valid block                                                */
    ptr = CLIENT_2_HDR (client_ptr);
    if (ptr-> tag != MEMTAG)
        mem_tag_err (ptr, filename, lineno);
}

| << | < | > | >> iMatix Copyright © 1996-2000 iMatix Corporation