diff options
author | Björn Steinbrink <B.Steinbrink@gmx.de> | 2007-04-22 13:39:22 +0000 |
---|---|---|
committer | Björn Steinbrink <B.Steinbrink@gmx.de> | 2007-04-22 13:39:22 +0000 |
commit | 9398626764574fa536dca3806490f88970d2f056 (patch) | |
tree | b8a5f938d6d6447846773a6270802c3595077222 /src/utils | |
parent | ccf4dd308bcb8a592ece2d86102bbaa7080f0f7e (diff) | |
download | mana-client-9398626764574fa536dca3806490f88970d2f056.tar.gz mana-client-9398626764574fa536dca3806490f88970d2f056.tar.bz2 mana-client-9398626764574fa536dca3806490f88970d2f056.tar.xz mana-client-9398626764574fa536dca3806490f88970d2f056.zip |
Added a macro for XML child node iterations to make the code more terse and easier to read.
Diffstat (limited to 'src/utils')
-rw-r--r-- | src/utils/xml.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/utils/xml.h b/src/utils/xml.h index bf01fc96..db4c264a 100644 --- a/src/utils/xml.h +++ b/src/utils/xml.h @@ -46,4 +46,7 @@ namespace XML getProperty(xmlNodePtr node, const char *name, const std::string &def); } +#define for_each_xml_child_node(var, parent) \ + for (xmlNodePtr var = parent->xmlChildrenNode; var; var = var->next) + #endif |