COHERENT manpages
This page displays the COHERENT manpage for gdbm_reorganize() [Reorganize a GDBM data base].
List of available manpages
Index
gdbm_reorganize() -- GDBM Function (libgdbm) Reorganize a GDBM data base #include <gdbm.h> int gdbm_reorganize(database) GDBM_FILE database; Function gdbm_reorganize() reorganizes the contents of the data base to which database points. database must have been returned by a call to gdbm_open(). When you delete a record from a GDBM data base, the GDBM routines to not close up the space within the data base, because doing so would make the GDBM routines unacceptably slow. Thus, if you delete many records from within a data base, its file will be much larger than it need be. In this case, you should call gdbm_reorganize() to close up the ``holes'' in it. gdbm_reorganize() returns zero if all went well. If something went wrong, it returns a value other than zero and sets the global variables errno and gdbm_errno to appropriate values. (For information on how to interpret the contents of these variables, see the Lexicon entries for errno.h and gdbmerrno.h). See Also Notes For a statement of copyright and permissions on this routine, see the Lexicon entry for libgdbm.