MCPcopy Create free account
hub / github.com/acl-dev/acl / xml_node_attrs

Function xml_node_attrs

lib_acl/samples/xml/xml6/xml.c:268–294  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

266}
267
268static void xml_node_attrs(ACL_XML3_NODE* node, int n)
269{
270 int i;
271 ACL_ITER iter;
272
273 acl_foreach(iter, node->attr_list) {
274 ACL_XML3_ATTR *attr = (ACL_XML3_ATTR*) iter.data;
275
276 for (i = 0; i < n; i++)
277 printf("\t");
278
279 printf("attr-><%s>(size=%ld)=\"<%s>(size=%ld)\"\n",
280 attr->name, (long) attr->name_size,
281 attr->value, (long) attr->value_size);
282
283 if (attr->name_size != strlen(attr->name)) {
284 printf("%s(%d): name_size invalid\r\n",
285 __FUNCTION__, __LINE__);
286 exit (1);
287 }
288 if (attr->value_size != strlen(attr->value)) {
289 printf("%s(%d): value_size invaid\r\n",
290 __FUNCTION__, __LINE__);
291 exit (1);
292 }
293 }
294}
295
296static void walk_xml_node(ACL_XML3_NODE *node, int n)
297{

Callers 2

walk_xml_nodeFunction · 0.70

Calls 1

acl_foreachFunction · 0.50

Tested by 1

Used in the wild real call sites across dependent graphs

searching dependent graphs…