d3d: Fix adapter mode enumeration and filtering.
[wine/hacks.git] / dlls / vdhcp.vxd / vdhcp.c
bloba7b97a338cbacdeea1bb47e9a93896d5400edec1
1 /*
2 * VDHCP VxD implementation
4 * Copyright 2003 Juan Lang
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.
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.
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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
21 #include <stdarg.h>
22 #include "windef.h"
23 #include "winbase.h"
24 #include "wine/debug.h"
26 WINE_DEFAULT_DEBUG_CHANNEL(vxd);
29 /***********************************************************************
30 * DeviceIoControl (VDHCP.VXD.@)
32 BOOL WINAPI VDHCP_DeviceIoControl(DWORD dwIoControlCode, LPVOID lpvInBuffer,
33 DWORD cbInBuffer,
34 LPVOID lpvOutBuffer, DWORD cbOutBuffer,
35 LPDWORD lpcbBytesReturned,
36 LPOVERLAPPED lpOverlapped)
38 DWORD error;
40 switch (dwIoControlCode)
42 case 1:
44 /* since IpReleaseAddress/IpRenewAddress are not implemented, say there
45 * are no DHCP adapters
47 error = ERROR_FILE_NOT_FOUND;
48 break;
51 /* FIXME: don't know what this means */
52 case 5:
53 if (lpcbBytesReturned)
54 *lpcbBytesReturned = sizeof(DWORD);
55 if (lpvOutBuffer && cbOutBuffer >= sizeof(DWORD))
57 *(LPDWORD)lpvOutBuffer = 0;
58 error = NO_ERROR;
60 else
61 error = ERROR_BUFFER_OVERFLOW;
62 break;
64 default:
65 FIXME("(%d,%p,%d,%p,%d,%p,%p): stub\n",
66 dwIoControlCode,
67 lpvInBuffer,cbInBuffer,
68 lpvOutBuffer,cbOutBuffer,
69 lpcbBytesReturned,
70 lpOverlapped);
71 error = ERROR_NOT_SUPPORTED;
72 break;
74 if (error)
75 SetLastError(error);
76 return error == NO_ERROR;