Document/RB_Get_RB_Document [ Functions ]
FUNCTION
Allocate and initialize an RB_Document structure.
SYNOPSIS
struct RB_Document *RB_Get_RB_Document( void )
RESULT
An initialized document structure.
SOURCE
{ struct RB_Document *document = 0; document = ( struct RB_Document * ) malloc( sizeof( struct RB_Document ) ); if ( document ) { document->cur_part = NULL; document->parts = NULL; document->links = NULL; document->headers = NULL; document->doctype = UNKNOWN; document->actions = No_Actions(); document->srctree = NULL; document->srcroot = NULL; document->docroot = NULL; document->singledoc_name = NULL; document->no_headers = 0; document->charset = NULL; document->extension = NULL; document->first_section_level = 1; document->doctype_name = NULL; document->doctype_location = NULL; } else { RB_Panic( "out of memory" ); } return document; }