Annotation of parser3/src/targets/isapi/pa_pool.C, revision 1.8

1.2       paf         1: /** @file
                      2:        Parser: ISAPI memory manager impl.
                      3: 
1.1       paf         4:        Copyright (c) 2001 ArtLebedev Group (http://www.artlebedev.com)
1.7       parser      5:        Author: Alexander Petrosyan <paf@design.ru> (http://design.ru/paf)
1.2       paf         6: 
1.8     ! paf         7:        $Id: pa_pool.C,v 1.7 2001/09/26 10:32:26 parser Exp $
1.1       paf         8: */
                      9: 
                     10: #include <stdlib.h>
                     11: 
                     12: #include "pa_pool.h"
1.3       paf        13: #include "pool_storage.h"
1.1       paf        14: 
1.8     ! paf        15: void *Pool::real_malloc(size_t size, int place) {
1.3       paf        16:        return fstorage?
                     17:                static_cast<Pool_storage *>(fstorage)->malloc(size): ::malloc(size);
1.1       paf        18: }
                     19: 
                     20: void *Pool::real_calloc(size_t size) {
1.3       paf        21:        return fstorage?
                     22:                static_cast<Pool_storage *>(fstorage)->calloc(size): ::calloc(size, 1);
1.1       paf        23: }
1.4       parser     24: 
1.5       parser     25: bool Pool::real_register_cleanup(void (*cleanup) (void *), void *data) {
                     26:        return fstorage!=0 && static_cast<Pool_storage *>(fstorage)->register_cleanup(cleanup, data);
1.4       parser     27: }

E-mail: