145,6 → 145,32 |
} |
|
/** |
* Returns the value of the string property of the given node. |
* |
* @param |
*/ |
bool md_get_string_property(md_node_t node, const char *key, |
const char **result) |
{ |
md_header_t *md_header = (md_header_t *) mach_desc; |
element_idx_t idx = node; |
|
while (get_element(idx)->tag != NODE_END) { |
idx++; |
md_element_t *element = get_element(idx); |
if (element->tag == PROP_DATA && |
strcmp(key, get_element_name(idx)) == 0) { |
*result = (char *) mach_desc + sizeof(md_header_t) + |
md_header->node_blk_sz + md_header->name_blk_sz + |
element->d.y.data_offset; |
return true; |
} |
} |
|
return false; |
} |
|
/** |
* Moves the child oterator to the next child (following sibling of the node |
* the oterator currently points to). |
* |