pike.git / src / modules / Gdbm / gdbmmod.c

version» Context lines:

pike.git/src/modules/Gdbm/gdbmmod.c:1:   /*\   ||| This file a part of Pike, and is copyright by Fredrik Hubinette   ||| Pike is distributed as GPL (General Public License)   ||| See the files COPYING and DISCLAIMER for more information.   \*/   #include "global.h" - RCSID("$Id: gdbmmod.c,v 1.5 1997/08/30 22:21:49 grubba Exp $"); + RCSID("$Id: gdbmmod.c,v 1.6 1999/02/01 02:42:09 hubbe Exp $");   #include "gdbm_machine.h"   #include "threads.h"      /* Todo: make sure only one thread accesses the same gdbmmod */      #if defined(HAVE_GDBM_H) && defined(HAVE_LIBGDBM)      #include "interpret.h"   #include "svalue.h"   #include "stralloc.h"
pike.git/src/modules/Gdbm/gdbmmod.c:327:   }      #endif      void pike_module_exit(void) {}      void pike_module_init(void)   {   #if defined(HAVE_GDBM_H) && defined(HAVE_LIBGDBM)    start_new_program(); -  add_storage(sizeof(struct gdbm_glue)); +  ADD_STORAGE(struct gdbm_glue);       add_function("create",gdbmmod_create,"function(void|string,void|string:void)",0);       add_function("close",gdbmmod_close,"function(:void)",0);    add_function("store",gdbmmod_store,"function(string,string:int)",0);    add_function("`[]=",gdbmmod_store,"function(string,string:int)",0);    add_function("fetch",gdbmmod_fetch,"function(string:string)",0);    add_function("`[]",gdbmmod_fetch,"function(string:string)",0);    add_function("delete",gdbmmod_delete,"function(string:int)",0);    add_function("firstkey",gdbmmod_firstkey,"function(:string)",0);    add_function("nextkey",gdbmmod_nextkey,"function(string:string)",0);    add_function("reorganize",gdbmmod_reorganize,"function(:int)",0);    add_function("sync",gdbmmod_sync,"function(:void)",0);       set_init_callback(init_gdbm_glue);    set_exit_callback(exit_gdbm_glue);    end_class("gdbm",0);   #endif   }