
Hello, On Thursday 26 January 2012 06:10:28 Zeeshan Ali (Khattak) wrote:
- it = node->children; - while (it != NULL) { + for (it = node->children; it != NULL; it = it->next) { ... - xmlNodePtr next = it->next; ... cont = iter_func(it, opaque); ... - it = next; Your changed version only has the same behaviour, if the user-passed-in function iter_func() never changes it->next, which you can't guarentee here. You need to keep the "next" copy.
BYtE Philipp -- Philipp Hahn Open Source Software Engineer hahn@univention.de Univention GmbH Linux for Your Business fon: +49 421 22 232- 0 Mary-Somerville-Str.1 D-28359 Bremen fax: +49 421 22 232-99 http://www.univention.de/