VPR-7.0
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros
read_settings.h File Reference
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

int read_settings_file (char *file_name, char ***outv)
 

Function Documentation

int read_settings_file ( char *  file_name,
char ***  outv 
)

Definition at line 53 of file read_settings.c.

54 {
55  ezxml_t Cur;
56  int count;
57 
58  Cur = ezxml_parse_file(file_name);
59  assert(*outv == NULL);
60  assert(! strcmp("settings",Cur->name));
61  Cur = FindElement(Cur, "arguments", FALSE);
62 
63  count = process_settings(Cur, *outv);
64 
65  /* prepend the settings file name */
66  count++;
67 
68  *outv = (char **)my_malloc(count * sizeof(char *));
69 
70  (*outv)[0] = my_strdup(file_name);
71 
72  if (count)
73  {
74  process_settings(Cur, &((*outv)[1]));
75  }
76 
77  return(count);
78 }
Definition: ezxml.h:44
Definition: util.h:12
static void * my_malloc(int ibytes)
Definition: graphics.c:499
ezxml_t FindElement(INP ezxml_t Parent, INP const char *Name, INP boolean Required)
Definition: read_xml_util.c:11
static int process_settings(ezxml_t Cur, char **outv)
Definition: read_settings.c:6
char * name
Definition: ezxml.h:45
ezxml_t ezxml_parse_file(const char *file)
Definition: ezxml.c:846
char * my_strdup(const char *str)
Definition: util.c:101

+ Here is the call graph for this function:

+ Here is the caller graph for this function: