Hans Leidekker : inetcomm: Add an implementation of IPOP3Transport:: CommandNOOP.
Alexandre Julliard
julliard at winehq.org
Mon Nov 10 07:43:48 CST 2008
Module: wine
Branch: master
Commit: 05312014fe3cff9855e879df0cc31118c4e90023
URL: http://source.winehq.org/git/wine.git/?a=commit;h=05312014fe3cff9855e879df0cc31118c4e90023
Author: Hans Leidekker <hans at codeweavers.com>
Date: Fri Nov 7 15:06:05 2008 +0100
inetcomm: Add an implementation of IPOP3Transport::CommandNOOP.
---
dlls/inetcomm/pop3transport.c | 36 ++++++++++++++++++++++++++++++++++--
1 files changed, 34 insertions(+), 2 deletions(-)
diff --git a/dlls/inetcomm/pop3transport.c b/dlls/inetcomm/pop3transport.c
index b6991eb..c3fe587 100644
--- a/dlls/inetcomm/pop3transport.c
+++ b/dlls/inetcomm/pop3transport.c
@@ -408,6 +408,32 @@ static void POP3Transport_CallbackRecvDELEResp(IInternetTransport *iface, char *
InternetTransport_ReadLine(&This->InetTransport, POP3Transport_CallbackProcessDELEResp);
}
+static void POP3Transport_CallbackProcessNOOPResp(IInternetTransport *iface, char *pBuffer, int cbBuffer)
+{
+ POP3Transport *This = (POP3Transport *)iface;
+ POP3RESPONSE response;
+ HRESULT hr;
+
+ TRACE("\n");
+
+ hr = POP3Transport_ParseResponse(This, pBuffer, &response);
+ if (FAILED(hr))
+ {
+ /* FIXME: handle error */
+ return;
+ }
+
+ IPOP3Callback_OnResponse((IPOP3Callback *)This->InetTransport.pCallback, &response);
+}
+
+static void POP3Transport_CallbackRecvNOOPResp(IInternetTransport *iface, char *pBuffer, int cbBuffer)
+{
+ POP3Transport *This = (POP3Transport *)iface;
+
+ TRACE("\n");
+ InternetTransport_ReadLine(&This->InetTransport, POP3Transport_CallbackProcessNOOPResp);
+}
+
static void POP3Transport_CallbackProcessLISTResp(IInternetTransport *iface, char *pBuffer, int cbBuffer)
{
POP3Transport *This = (POP3Transport *)iface;
@@ -845,8 +871,14 @@ static HRESULT WINAPI POP3Transport_CommandSTAT(IPOP3Transport *iface)
static HRESULT WINAPI POP3Transport_CommandNOOP(IPOP3Transport *iface)
{
- FIXME("()\n");
- return E_NOTIMPL;
+ static char noop[] = "NOOP\r\n";
+ POP3Transport *This = (POP3Transport *)iface;
+
+ TRACE("\n");
+
+ init_parser(This, POP3_NOOP, POP3_NONE);
+ InternetTransport_DoCommand(&This->InetTransport, noop, POP3Transport_CallbackRecvNOOPResp);
+ return S_OK;
}
static HRESULT WINAPI POP3Transport_CommandRSET(IPOP3Transport *iface)
More information about the wine-cvs
mailing list