From 555ba77568b6faf18ebaed06cd08615deab2d8e3 Mon Sep 17 00:00:00 2001 From: Mike Buland Date: Sat, 7 Jun 2008 05:30:58 +0000 Subject: This is a testing version. Nothing should be broken, but I won't gurantee it. I wouldn't update to this just yet, if you have problems, back off a rev. I'm trying to update the code to work on both 32bit, and 64bit systems, and hopefully anything else that comes along. Currently some of the archive code is broken, testing must be done on both archetectures. --- src/exceptionbase.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src/exceptionbase.cpp') diff --git a/src/exceptionbase.cpp b/src/exceptionbase.cpp index cea779d..9515e2d 100644 --- a/src/exceptionbase.cpp +++ b/src/exceptionbase.cpp @@ -55,7 +55,10 @@ void Bu::ExceptionBase::setWhat( const char *lpFormat, va_list &vargs ) if( sWhat ) delete[] sWhat; int nSize; - nSize = vsnprintf( NULL, 0, lpFormat, vargs ); + va_list vargs2; + va_copy( vargs2, vargs ); + nSize = vsnprintf( NULL, 0, lpFormat, vargs2 ); + va_end( vargs2 ); sWhat = new char[nSize+1]; vsnprintf( sWhat, nSize+1, lpFormat, vargs ); } -- cgit v1.2.3