[Libreoffice-commits] .: Branch 'libreoffice-3-5' - sal/inc sal/systools

Libreoffice Gerrit user logerrit at kemper.freedesktop.org
Wed Sep 12 03:20:31 PDT 2012


 sal/inc/systools/win32/snprintf.h      |    3 +++
 sal/systools/win32/uwinapi/sntprintf.c |    4 ++++
 2 files changed, 7 insertions(+)

New commits:
commit 89fb2852ed677a9bd7e49af8457ef0dd395bb9a3
Author: Jan Holesovsky <kendy at suse.cz>
Date:   Fri Feb 24 18:35:17 2012 +0100

    MinGW: snprintf might be present.
    
    Signed-off-by: Luboš Luňák <l.lunak at suse.cz>

diff --git a/sal/inc/systools/win32/snprintf.h b/sal/inc/systools/win32/snprintf.h
index cfed10f..fe4f5de 100644
--- a/sal/inc/systools/win32/snprintf.h
+++ b/sal/inc/systools/win32/snprintf.h
@@ -49,6 +49,7 @@ extern "C" {
     enough to hold the string. */
 
 
+#if !defined(__MINGW32__) || defined (__NO_ISOCEXT)
 
 /* UNICODE version */
 _SNPRINTF_DLLIMPORT int __cdecl snwprintf( wchar_t *buffer, size_t count, const wchar_t *format, ... );
@@ -56,6 +57,8 @@ _SNPRINTF_DLLIMPORT int __cdecl snwprintf( wchar_t *buffer, size_t count, const
 /* SBCS and MBCS version */
 _SNPRINTF_DLLIMPORT int __cdecl snprintf( char *buffer, size_t count, const char *format, ... );
 
+#endif
+
 /* Conflict with STL_port inline implementation */
 
 #ifdef __cplusplus
diff --git a/sal/systools/win32/uwinapi/sntprintf.c b/sal/systools/win32/uwinapi/sntprintf.c
index 424e5bd..c519da3 100644
--- a/sal/systools/win32/uwinapi/sntprintf.c
+++ b/sal/systools/win32/uwinapi/sntprintf.c
@@ -40,6 +40,8 @@ static int __cdecl _vsctprintf( const _TXCHAR *format, va_list ap )
 }
 #endif
 
+#if !defined(__MINGW32__) || defined (__NO_ISOCEXT)
+
 /*  This function retrieves the pointer to the last character of a buffer.
     That is the pointer to the last character of the buffer that fits
     completly into that buffer or the position of the terminating zero.
@@ -122,4 +124,6 @@ _SNPRINTF_DLLIMPORT int __cdecl sntprintf( _TCHAR *buffer, size_t count, const _
     return retval;
 }
 
+#endif
+
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */


More information about the Libreoffice-commits mailing list