![wiz](/assets/img/avatar_default.png)
Make sure that each va_start has one and only one matching va_end, especially in error cases. If the va_list is used multiple times, do multiple va_starts/va_ends. If a function gets va_list as argument, don't let it use va_end (since it's the callers responsibility). Improved by comments from enami and christos -- thanks! Heimdal/krb4/KAME changes already fed back, rest to follow. Inspired by, but not not based on, OpenBSD.
In case you were wondering why this code is still present: The ISO (or OSI) stack is still in use by many router vendors (e.g., using IS-IS the OSI equivalent of OSPF, to carry IP routes). Chris. chopps@netbsd.org