Detlef Riekenberg : localspl: Implement DeletePort for XcvDataPort.
Alexandre Julliard
julliard at wine.codeweavers.com
Wed Mar 7 07:16:42 CST 2007
Module: wine
Branch: master
Commit: 9827e5d24e113c19457dc7ed0d540b5f802996f7
URL: http://source.winehq.org/git/wine.git/?a=commit;h=9827e5d24e113c19457dc7ed0d540b5f802996f7
Author: Detlef Riekenberg <wine.dev at web.de>
Date: Wed Mar 7 00:20:25 2007 +0100
localspl: Implement DeletePort for XcvDataPort.
---
dlls/localspl/localmon.c | 13 +++++++++++++
1 files changed, 13 insertions(+), 0 deletions(-)
diff --git a/dlls/localspl/localmon.c b/dlls/localspl/localmon.c
index c195c17..c98611d 100644
--- a/dlls/localspl/localmon.c
+++ b/dlls/localspl/localmon.c
@@ -65,6 +65,7 @@ static struct list xcv_handles = LIST_INIT( xcv_handles );
/* ############################### */
+static const WCHAR cmd_DeletePortW[] = {'D','e','l','e','t','e','P','o','r','t',0};
static const WCHAR cmd_ConfigureLPTPortCommandOKW[] = {'C','o','n','f','i','g','u','r','e',
'L','P','T','P','o','r','t',
'C','o','m','m','a','n','d','O','K',0};
@@ -468,6 +469,18 @@ DWORD WINAPI localmon_XcvDataPort(HANDLE hXcv, LPCWSTR pszDataName, PBYTE pInput
return res;
}
+ if (!lstrcmpW(pszDataName, cmd_DeletePortW)) {
+ TRACE("InputData (%d): %s\n", cbInputData, debugstr_w( (LPWSTR) pInputData));
+ res = RegOpenKeyW(HKEY_LOCAL_MACHINE, WinNT_CV_PortsW, &hroot);
+ if (res == ERROR_SUCCESS) {
+ res = RegDeleteValueW(hroot, (LPWSTR) pInputData);
+ RegCloseKey(hroot);
+ TRACE("=> %u with %u\n", res, GetLastError() );
+ return res;
+ }
+ return ERROR_FILE_NOT_FOUND;
+ }
+
if (!lstrcmpW(pszDataName, cmd_GetDefaultCommConfigW)) {
TRACE("InputData (%d): %s\n", cbInputData, debugstr_w( (LPWSTR) pInputData));
*pcbOutputNeeded = cbOutputData;
More information about the wine-cvs
mailing list