[WINHTTP]
authorAmine Khaldi <amine.khaldi@reactos.org>
Wed, 1 Jan 2014 21:42:31 +0000 (21:42 +0000)
committerAmine Khaldi <amine.khaldi@reactos.org>
Wed, 1 Jan 2014 21:42:31 +0000 (21:42 +0000)
* Move some inclusions to the main header.
* Set the default debugging channel globally through the main header.
* Remove inclusions and definitions that already exist in the main header.
CORE-7716

svn path=/trunk/; revision=61478

reactos/dll/win32/winhttp/cookie.c
reactos/dll/win32/winhttp/handle.c
reactos/dll/win32/winhttp/main.c
reactos/dll/win32/winhttp/net.c
reactos/dll/win32/winhttp/request.c
reactos/dll/win32/winhttp/session.c
reactos/dll/win32/winhttp/url.c
reactos/dll/win32/winhttp/winhttp_private.h

index 661cc79..e340dbe 100644 (file)
  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
  */
 
-#define WIN32_NO_STATUS
-#define _INC_WINDOWS
-#define COM_NO_WINDOWS_H
-
-#include <config.h>
-//#include <stdarg.h>
-
-#include <wine/debug.h>
-//#include "wine/list.h"
-
-//#include "windef.h"
-#include <winbase.h>
-#include <winhttp.h>
-
 #include "winhttp_private.h"
 
-WINE_DEFAULT_DEBUG_CHANNEL(winhttp);
-
 static domain_t *add_domain( session_t *session, WCHAR *name )
 {
     domain_t *domain;
index 16bd601..f7d1b39 100644 (file)
  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
  */
 
-#define WIN32_NO_STATUS
-#define _INC_WINDOWS
-#define COM_NO_WINDOWS_H
-
-#include <config.h>
-//#include "wine/port.h"
-#include <wine/debug.h>
-
-//#include <stdarg.h>
-
-//#include "windef.h"
-#include <winbase.h>
-#include <winhttp.h>
-
 #include "winhttp_private.h"
 
-WINE_DEFAULT_DEBUG_CHANNEL(winhttp);
-
 #define HANDLE_CHUNK_SIZE 0x10
 
 static CRITICAL_SECTION handle_cs;
index 7a442dc..1707a34 100644 (file)
  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
  */
 
-#define WIN32_NO_STATUS
-#define _INC_WINDOWS
-#define COM_NO_WINDOWS_H
-
-#define COBJMACROS
-#include <config.h>
-#include <stdarg.h>
+#include "winhttp_private.h"
 
-#include <windef.h>
-#include <winbase.h>
-#include <objbase.h>
 #include <rpcproxy.h>
 #include <httprequest.h>
-#include <winhttp.h>
-
-#include <wine/debug.h>
-#include "winhttp_private.h"
 
 static HINSTANCE instance;
 
-WINE_DEFAULT_DEBUG_CHANNEL(winhttp);
-
 /******************************************************************
  *              DllMain (winhttp.@)
  */
index cbf642d..0f5dc7f 100644 (file)
  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
  */
 
-#define WIN32_NO_STATUS
-#define _INC_WINDOWS
-#define COM_NO_WINDOWS_H
-
-#include <config.h>
-//#include <wine/port.h>
+#include "winhttp_private.h"
 
-//#include <stdarg.h>
-//#include <stdio.h>
-//#include <errno.h>
 #include <assert.h>
+#include <schannel.h>
 
-//#include <sys/types.h>
 #ifdef HAVE_SYS_SOCKET_H
 # include <sys/socket.h>
 #endif
 # include <poll.h>
 #endif
 
-#define NONAMELESSUNION
-
-#include <wine/debug.h>
-#include <wine/library.h>
-
-//#include "windef.h"
-//#include "winbase.h"
-#include <winhttp.h>
-//#include "wincrypt.h"
-#include <schannel.h>
-
-#include "winhttp_private.h"
-
-/* to avoid conflicts with the Unix socket headers */
-#define USE_WS_PREFIX
-//#include "winsock2.h"
-
-WINE_DEFAULT_DEBUG_CHANNEL(winhttp);
-
 #ifndef HAVE_GETADDRINFO
 
 /* critical section to protect non-reentrant gethostbyname() */
index 8da3a2e..fd113d4 100644 (file)
  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
  */
 
-#define WIN32_NO_STATUS
-#define _INC_WINDOWS
-#define COM_NO_WINDOWS_H
-
-#define COBJMACROS
-#include <config.h>
-//#include "wine/port.h"
-#include <wine/debug.h>
+#include "winhttp_private.h"
 
-#include <stdarg.h>
 #ifdef HAVE_ARPA_INET_H
 # include <arpa/inet.h>
 #endif
 
-#include <windef.h>
-#include <winbase.h>
-#include <ole2.h>
-//#include "initguid.h"
+#include <winuser.h>
 #include <httprequest.h>
-#include <winhttp.h>
-
-#include "winhttp_private.h"
 
 #include "inet_ntop.c"
 
-WINE_DEFAULT_DEBUG_CHANNEL(winhttp);
-
 static const WCHAR attr_accept[] = {'A','c','c','e','p','t',0};
 static const WCHAR attr_accept_charset[] = {'A','c','c','e','p','t','-','C','h','a','r','s','e','t', 0};
 static const WCHAR attr_accept_encoding[] = {'A','c','c','e','p','t','-','E','n','c','o','d','i','n','g',0};
index d5dae41..9f23a8d 100644 (file)
  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
  */
 
-#define WIN32_NO_STATUS
-#define _INC_WINDOWS
-#define COM_NO_WINDOWS_H
-
-#include <config.h>
-//#include "wine/port.h"
-#include <wine/debug.h>
-
-//#include <stdarg.h>
-//#include <stdlib.h>
+#include "winhttp_private.h"
 
-#include <windef.h>
-#include <winbase.h>
-#include <winsock2.h>
-#include <winhttp.h>
 #include <wincrypt.h>
 #include <winreg.h>
-#define COBJMACROS
-#include <ole2.h>
 #include <dispex.h>
 #include <activscp.h>
 
-#include "winhttp_private.h"
-
-WINE_DEFAULT_DEBUG_CHANNEL(winhttp);
-
 #define DEFAULT_RESOLVE_TIMEOUT     0
 #define DEFAULT_CONNECT_TIMEOUT     20000
 #define DEFAULT_SEND_TIMEOUT        30000
index b6cfb15..684d1c0 100644 (file)
  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
  */
 
-#define WIN32_NO_STATUS
-#define _INC_WINDOWS
-#define COM_NO_WINDOWS_H
-
-#include <config.h>
-//#include <stdarg.h>
-
-#include <wine/debug.h>
-
-//#include "windef.h"
-#include <winbase.h>
-//#include "winreg.h"
-#include <winhttp.h>
-//#include "shlwapi.h"
-
 #include "winhttp_private.h"
 
-WINE_DEFAULT_DEBUG_CHANNEL(winhttp);
-
 static const WCHAR scheme_http[] = {'h','t','t','p',0};
 static const WCHAR scheme_https[] = {'h','t','t','p','s',0};
 
index 2413d82..e1ca4a7 100644 (file)
 #ifndef _WINE_WINHTTP_PRIVATE_H_
 #define _WINE_WINHTTP_PRIVATE_H_
 
-#ifndef __WINE_CONFIG_H
-# error You must include config.h to use this header
-#endif
+#include <wine/config.h>
+
+#include <stdarg.h>
+
+#define WIN32_NO_STATUS
+#define _INC_WINDOWS
+#define COM_NO_WINDOWS_H
+
+#define COBJMACROS
+#define NONAMELESSUNION
+
+#include <windef.h>
+#include <winbase.h>
+#include <objbase.h>
+#include <oleauto.h>
+#include <winsock2.h>
+#include <winhttp.h>
 
 #include <wine/list.h>
 #include <wine/unicode.h>
 
-//#include <sys/types.h>
 #ifdef HAVE_SYS_SOCKET_H
 # include <sys/socket.h>
 #endif
 # define closesocket close
 # define ioctlsocket ioctl
 #endif
-#include <ole2.h>
+
 #include <sspi.h>
 
+#include <wine/debug.h>
+WINE_DEFAULT_DEBUG_CHANNEL(winhttp);
+
 static const WCHAR getW[]    = {'G','E','T',0};
 static const WCHAR postW[]   = {'P','O','S','T',0};
 static const WCHAR headW[]   = {'H','E','A','D',0};