00001 /*---------------------------------------------------------------------------
00002
00003 File name : bad_cfg.c
00004 Autor : Juergen Schreiber
00005 Created on : October 2001
00006 Description : handles the data structure bad_config
00007
00008 *--------------------------------------------------------------------------*/
00009
00010 /*---------------------------------------------------------------------------
00011 Includes
00012 ---------------------------------------------------------------------------*/
00013
00014 #include "bad_cfg.h"
00015
00016 /*---------------------------------------------------------------------------
00017 Function codes
00018 ---------------------------------------------------------------------------*/
00019
00020 /*---------------------------------------------------------------------------
00021 Function : bad_cfg_create()
00022 In : void
00023 Out : pointer to allocated base bad_config structure
00024 Job : allocate memory for a bad_config struct
00025 Notice : only the main (base) structure is allocated
00026 ---------------------------------------------------------------------------*/
00027
00028 bad_config * bad_cfg_create(void)
00029 {
00030 return calloc(1, sizeof(bad_config));
00031 }
00032
00033
00034 /*---------------------------------------------------------------------------
00035 Function : bad_cfg_destroy()
00036 In : bad_config to deallocate
00037 Out : void
00038 Job : deallocate all memory associated with a bad_config data structure
00039 Notice :
00040 ---------------------------------------------------------------------------*/
00041
00042 void bad_cfg_destroy(bad_config * sc)
00043 {
00044
00045 if (sc==NULL) return ;
00046
00047 /* Free main struct */
00048 free(sc);
00049
00050 return ;
00051 }
00052
00053
00054
00055
1.2.13.1 written by Dimitri van Heesch,
© 1997-2001