]> granicus.if.org Git - nethack/commit
impossible fix - potentially invalid feedback
authornethack.rankin <nethack.rankin>
Sat, 9 Feb 2013 01:33:37 +0000 (01:33 +0000)
committernethack.rankin <nethack.rankin>
Sat, 9 Feb 2013 01:33:37 +0000 (01:33 +0000)
commit1183aa680594bdc3975c559a47b3651c09ad610c
tree0675ddbab6a10ca385f605545c26ee013cc1bfa1
parent6847b78316948ba79a33335ef6430f95a6c6ac84
impossible fix - potentially invalid feedback

     From a bug report, the message displayed to the screen by
impossible() might be different from the one written into paniclog, if it
had argument subsitution/formatting.  I couldn't reproduce that myself,
but stdarg.h/varargs.h is tricky stuff and I think that passing the va_list
to a routine which steps through it requires that va_start be called again
if you're going to use the va_list a second time.  This changes impossible()
to handle its arguments only once, like panic().
doc/fixes35.0
src/pline.c