2 ===================================================================
3 --- gmetad/server.c (revision 1953)
4 +++ gmetad/server.c (working copy)
7 /* sacerdoti: This function does a tree walk while respecting the filter path.
8 * Will return valid XML even if we have chosen a subtree. Since tree depth is
9 - * bounded, this function guarantees O(1) search time. The recursive structure
10 - * does not require any memory allocations.
11 + * bounded, this function guarantees O(1) search time.
14 process_path (client_t *client, char *path, datum_t *myroot, datum_t *key)
16 char *p, *q, *pathend;
26 + element = malloc(len + 1);
27 + if ( element == NULL )
29 strncpy(element, p, len);
34 rc = process_path(client, 0, myroot, NULL);
44 - char request[REQUESTLEN];
45 + char request[REQUESTLEN + 1];