[PATCH] missing va_end() in some IO functions (gmp 6.1.2)
Torbjörn Granlund
tg at gmplib.org
Thu Mar 14 15:57:18 UTC 2019
Vincent Lefevre <vincent at vinc17.net> writes:
> #define va_copy(dst,src) \
> do { memcpy (&(dst), &(src), sizeof (va_list)); } while (0)
> #endif
But will va_arg necessarily work when va_copy is just a memcpy
(at least in the case where va_end is *not* empty)? This seems
optimistic.
A good question. This is old code, and I don't know how broadly it was
tested outside the realm of gcc.
To check this, we'd need some environments with just a c90 compiler
which also does not provide va_copy as a courtesy.
--
Torbjörn
Please encrypt, key id 0xC8601622
More information about the gmp-bugs
mailing list