Move implementation of EnumProtocols{A,W} from wsock32 to ws2_32.
[wine] / dlls / wsock32 / protocol.c
1 /*
2  * WSOCK32 specific functions
3  *
4  * Copyright (C) 2001 Stefan Leichter
5  *
6  * This library is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU Lesser General Public
8  * License as published by the Free Software Foundation; either
9  * version 2.1 of the License, or (at your option) any later version.
10  *
11  * This library is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
14  * Lesser General Public License for more details.
15  *
16  * You should have received a copy of the GNU Lesser General Public
17  * License along with this library; if not, write to the Free Software
18  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
19  */
20
21 #define USE_WS_PREFIX
22
23 #include "config.h"
24
25 #include <stdarg.h>
26 #include <stdio.h>
27 #include <string.h>
28
29 #ifdef HAVE_ARPA_INET_H
30 #include <arpa/inet.h>
31 #endif
32 #ifdef HAVE_NETDB_H
33 #include <netdb.h>
34 #endif
35
36 #include "windef.h"
37 #include "winbase.h"
38 #include "winsock2.h"
39
40 #include "wine/unicode.h"
41 #include "wine/debug.h"
42
43 WINE_DEFAULT_DEBUG_CHANNEL(winsock);
44
45 /*****************************************************************************
46  *          inet_network       [WSOCK32.1100]
47  */
48 UINT WINAPI WSOCK32_inet_network(const char *cp)
49 {
50 #ifdef HAVE_INET_NETWORK
51     return inet_network(cp);
52 #else
53     return 0;
54 #endif
55 }
56
57 /*****************************************************************************
58  *          getnetbyname       [WSOCK32.1101]
59  */
60 struct netent * WINAPI WSOCK32_getnetbyname(const char *name)
61 {
62 #ifdef HAVE_GETNETBYNAME
63     return getnetbyname(name);
64 #else
65     return NULL;
66 #endif
67 }