[Xquartz-changes] xserver: Branch 'master'

Jeremy Huddleston jeremyhu at freedesktop.org
Thu May 5 09:09:49 PDT 2011


 os/log.c |    7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

New commits:
commit b47d2e43eb2cb3817c995d1f7e58500fb40efa2b
Author: Jeremy Huddleston <jeremyhu at apple.com>
Date:   Thu May 5 09:04:41 2011 -0700

    XQuartz: Make a copy of args for our crash reporter vsnprintf
    
    Signed-off-by: Jeremy Huddleston <jeremyhu at apple.com>

diff --git a/os/log.c b/os/log.c
index 9579e58..4a310e6 100644
--- a/os/log.c
+++ b/os/log.c
@@ -528,7 +528,12 @@ FatalError(const char *f, ...)
 
     va_start(args, f);
 #ifdef __APPLE__
-    (void)vsnprintf(__crashreporter_info_buff__, sizeof(__crashreporter_info_buff__), f, args);
+    {
+        va_list args2;
+        va_copy(args2, args);
+        (void)vsnprintf(__crashreporter_info_buff__, sizeof(__crashreporter_info_buff__), f, args2);
+        va_end(args2);
+    }
 #endif
     VErrorF(f, args);
     va_end(args);


More information about the Xquartz-changes mailing list