From: Francesco Chemolli Date: Sat, 1 Sep 2012 14:24:50 +0000 (+0200) Subject: Moved windows-related prototypes to new win32.h header file. X-Git-Tag: sourceformat-review-1~17 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=93bdc610eec1ee0289054aa4a247d4bbc3d1dd5f;p=thirdparty%2Fsquid.git Moved windows-related prototypes to new win32.h header file. --- diff --git a/compat/os/mswin.h b/compat/os/mswin.h index ad685ea554..b4748beeec 100644 --- a/compat/os/mswin.h +++ b/compat/os/mswin.h @@ -1,6 +1,4 @@ /* - * $Id$ - * * AUTHOR: Andrey Shorin * AUTHOR: Guido Serassio * diff --git a/src/Makefile.am b/src/Makefile.am index 3ba1d71eba..4afc3dd211 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -146,6 +146,7 @@ UNLINKD = endif WIN32_ALL_SOURCE = \ + win32.h \ win32.cc \ WinSvc.h \ WinSvc.cc diff --git a/src/protos.h b/src/protos.h index c5bc195e7c..6932660359 100644 --- a/src/protos.h +++ b/src/protos.h @@ -43,17 +43,6 @@ extern void shut_down(int); extern void rotate_logs(int); extern void reconfigure(int); -#if _SQUID_MSWIN_ - - SQUIDCEXTERN int WIN32_pipe(int[2]); - - SQUIDCEXTERN int WIN32_getrusage(int, struct rusage *); - SQUIDCEXTERN void WIN32_ExceptionHandlerInit(void); - - SQUIDCEXTERN int Win32__WSAFDIsSet(int fd, fd_set* set); - SQUIDCEXTERN DWORD WIN32_IpAddrChangeMonitorInit(); - -#endif diff --git a/src/win32.cc b/src/win32.cc index 6a80b6e920..7d2bfd64f9 100644 --- a/src/win32.cc +++ b/src/win32.cc @@ -1,6 +1,4 @@ /* - * $Id$ - * * Windows support * AUTHOR: Guido Serassio * inspired by previous work by Romeo Anghelache & Eric Stern. @@ -35,6 +33,7 @@ #include "squid.h" #include "squid_windows.h" +#include "win32.h" #if _SQUID_MSWIN_ #if HAVE_WIN32_PSAPI diff --git a/src/win32.h b/src/win32.h new file mode 100644 index 0000000000..04593a74c3 --- /dev/null +++ b/src/win32.h @@ -0,0 +1,64 @@ +#ifndef SQUID_WIN32_H_ +#define SQUID_WIN32_H_ +/* + * Windows support + * AUTHOR: Guido Serassio + * inspired by previous work by Romeo Anghelache & Eric Stern. + * + * SQUID Web Proxy Cache http://www.squid-cache.org/ + * ---------------------------------------------------------- + * + * Squid is the result of efforts by numerous individuals from + * the Internet community; see the CONTRIBUTORS file for full + * details. Many organizations have provided support for Squid's + * development; see the SPONSORS file for full details. Squid is + * Copyrighted (C) 2001 by the Regents of the University of + * California; see the COPYRIGHT file for full details. Squid + * incorporates software developed and/or copyrighted by other + * sources; see the CREDITS file for full details. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA. + * + */ + + +#if _SQUID_MSWIN_ + +#if HAVE_SYS_TIME_H +#include +#endif +#if HAVE_SYS_RESOURCE_H +#include +#endif +#if HAVE_SYS_SELECT_H +#include +#endif +#if HAVE_SYS_TYPES_H +#include +#endif + +extern int WIN32_pipe(int[2]); + +extern int WIN32_getrusage(int, struct rusage *); +extern void WIN32_ExceptionHandlerInit(void); + +extern int Win32__WSAFDIsSet(int fd, fd_set* set); +extern DWORD WIN32_IpAddrChangeMonitorInit(); + +#endif + + + +#endif /* SQUID_WIN32_H_ */