Kaydet (Commit) 729d1c1d authored tarafından Damjan Jovanovic's avatar Damjan Jovanovic

#i126787# fix unit tests on Windows

Fix a regression caused by r1710853 and which always existed in some files,
where <prewin.h> and <postwin.h> were being included before and after
<windows.h>, yet unavailable as the tools module isn't built (and can't be)
before sal.

Patch by: j.nitschke at ok.de
Review by: me
üst 002caf7f
......@@ -107,13 +107,10 @@ const sal_Char pBuffer_Blank[] = "";
# define PATH_SEPERATOR "/"
#endif
#if (defined WNT ) // Windows
#include <tools/prewin.h>
// # include <windows.h>
# include <tchar.h>
# include <io.h>
# include <stdio.h>
# include <stdlib.h>
#include <tools/postwin.h>
# define PATH_MAX MAX_PATH
# define TEST_PLATFORM "c:/"
# define TEST_PLATFORM_ROOT "c:/"
......
......@@ -35,10 +35,7 @@
# include <unistd.h>
#endif
#if ( defined WNT ) // Windows
#include <tools/prewin.h>
// # include <windows.h>
# include <io.h>
#include <tools/postwin.h>
#endif
# define FILE_PREFIX "file:///"
......
......@@ -31,10 +31,8 @@
#include <osl_Mutex_Const.h>
#ifdef WNT
#include <tools/prewin.h>
#define WIN32_LEAN_AND_MEAN
#include <windows.h>
#include <tools/postwin.h>
#endif
using namespace osl;
......
......@@ -36,12 +36,9 @@
#include <stdlib.h>
#include <osl/module.hxx>
#if ( defined WNT ) // Windows
#include <tools/prewin.h>
# define WIN32_LEAN_AND_MEAN
// # include <windows.h>
# include <tchar.h>
#include <tools/postwin.h>
#ifdef WNT // Windows
#define WIN32_LEAN_AND_MEAN
#include <tchar.h>
#endif
#include <iostream>
......
......@@ -27,16 +27,13 @@
//########################################
// includes
#if ( defined WNT ) // Windows
#include <tools/prewin.h>
# define UNICODE
# define _UNICODE
# define WIN32_LEAN_AND_MEAN
// # include <windows.h>
# include <tchar.h>
#include <tools/postwin.h>
#ifdef WNT // Windows
#define UNICODE
#define _UNICODE
#define WIN32_LEAN_AND_MEAN
#include <tchar.h>
#else
# include <unistd.h>
#include <unistd.h>
#endif
#include <stdio.h>
......
......@@ -28,11 +28,7 @@
#define _OSL_SECURITY_CONST_H_
#if ( defined WNT ) // Windows
//#define UNICODE
#include <tools/prewin.h>
// #include <windows.h>
#include <io.h>
#include <tools/postwin.h>
#endif
//------------------------------------------------------------------------
......
......@@ -86,11 +86,8 @@ extern "C"
# include <arpa/inet.h>
#endif
#if ( defined WNT ) // Windows
#include <tools/prewin.h>
// # include <windows.h>
# include <winsock.h>
# include <string.h>
#include <tools/postwin.h>
#endif
......
......@@ -86,11 +86,8 @@ extern "C"
# include <arpa/inet.h>
#endif
#if ( defined WNT ) // Windows
#include <tools/prewin.h>
// # include <windows.h>
# include <winsock.h>
# include <string.h>
#include <tools/postwin.h>
#endif
......
......@@ -83,11 +83,8 @@ extern "C"
#ifndef _OSL_SOCKET_CONST_H_
#if ( defined WNT ) // Windows
#include <tools/prewin.h>
// #include <windows.h>
#include <winsock.h>
#include <string.h>
#include <tools/postwin.h>
#endif
#endif
......
......@@ -34,9 +34,7 @@
#ifdef WNT
#define WIN32_LEAN_AND_MEAN
#include <tools/prewin.h>
#include <windows.h>
#include <tools/postwin.h>
#endif
#include "gtest/gtest.h"
......
......@@ -39,7 +39,7 @@ rtl::OUString CreateMD5FromString( const rtl::OUString& aMsg )
// BACK: Str "ababab....0f" Hexcode String
rtlDigest handle = rtl_digest_create( rtl_Digest_AlgorithmMD5 );
if ( handle > 0 )
if ( handle != NULL )
{
const sal_uInt8* pData = (const sal_uInt8*)aMsg.getStr();
sal_uInt32 nSize = ( aMsg.getLength() * sizeof( sal_Unicode ));
......
......@@ -42,9 +42,7 @@
#ifdef WNT
#define WIN32_LEAN_AND_MEAN
#include <tools/prewin.h>
#include <windows.h>
#include <tools/postwin.h>
#endif
// -----------------------------------------------------------------------------
......
......@@ -46,12 +46,7 @@
// #endif
#include <osl/file.hxx>
#if ( defined WNT ) // Windows
#include <tools/prewin.h>
// #define UNICODE
// #define WIN32_LEAN_AND_MEAN
// #include <windows.h>
#include <tchar.h>
#include <tools/postwin.h>
#endif
using namespace ::osl;
......
......@@ -33,9 +33,7 @@
#ifdef WNT
#define WIN32_LEAN_AND_MEAN
#include <tools/prewin.h>
#include <windows.h>
#include <tools/postwin.h>
#endif
#ifdef UNX
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment