From cf14e7a52f6c6a30b3a27474728dd75b241828d0 Mon Sep 17 00:00:00 2001 From: RĂ¼diger Timm Date: Mon, 31 Jan 2005 10:10:29 +0000 Subject: INTEGRATION: CWS hrobeta1 (1.8.64); FILE MERGED 2004/12/14 11:55:22 hro 1.8.64.1: #i34429# Output trace messages to debugger --- sal/osl/w32/diagnose.c | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) (limited to 'sal') diff --git a/sal/osl/w32/diagnose.c b/sal/osl/w32/diagnose.c index 214fe90e5ab7..ec841094be59 100644 --- a/sal/osl/w32/diagnose.c +++ b/sal/osl/w32/diagnose.c @@ -2,9 +2,9 @@ * * $RCSfile: diagnose.c,v $ * - * $Revision: 1.8 $ + * $Revision: 1.9 $ * - * last change: $Author: hjs $ $Date: 2004-06-25 18:36:36 $ + * last change: $Author: rt $ $Date: 2005-01-31 11:10:29 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -64,6 +64,7 @@ #define NO_DEBUG_CRT #include +#include< osl/thread.h> #define NO_DEBUG_CRT @@ -108,6 +109,14 @@ void SAL_CALL osl_trace(const sal_Char* lpszFormat, ...) #endif #endif + if ( IsDebuggerPresent() ) + { + sal_Char szMessage[512]; + szMessage[sizeof(szMessage)-1] = 0; + _vsnprintf( szMessage, sizeof(szMessage) -1, lpszFormat, args ); + OutputDebugString( szMessage ); + } + vfprintf(stderr,lpszFormat, args); fprintf(stderr,"\n"); -- cgit