Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
1020a7b0
Commit
1020a7b0
authored
Jun 17, 2013
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
inetcomm: Only set the command type when the command expects a reply.
parent
ee664704
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
19 additions
and
15 deletions
+19
-15
pop3transport.c
dlls/inetcomm/pop3transport.c
+19
-15
No files found.
dlls/inetcomm/pop3transport.c
View file @
1020a7b0
...
...
@@ -311,11 +311,10 @@ static HRESULT parse_top_response(POP3Transport *This, POP3TOP *top)
}
}
static
void
init_parser
(
POP3Transport
*
This
,
POP3COMMAND
command
,
POP3CMDTYPE
type
)
static
void
init_parser
(
POP3Transport
*
This
,
POP3COMMAND
command
)
{
This
->
state
=
STATE_NONE
;
This
->
command
=
command
;
This
->
type
=
type
;
}
static
HRESULT
POP3Transport_ParseResponse
(
POP3Transport
*
This
,
char
*
pszResponse
,
POP3RESPONSE
*
pResponse
)
...
...
@@ -659,7 +658,7 @@ static void POP3Transport_CallbackProcessUSERResp(IInternetTransport *iface, cha
strcat
(
command
,
This
->
InetTransport
.
ServerInfo
.
szPassword
);
strcat
(
command
,
"
\r\n
"
);
init_parser
(
This
,
POP3_PASS
,
POP3_NONE
);
init_parser
(
This
,
POP3_PASS
);
InternetTransport_DoCommand
(
&
This
->
InetTransport
,
command
,
POP3Transport_CallbackRecvPASSResp
);
HeapFree
(
GetProcessHeap
(),
0
,
command
);
...
...
@@ -800,7 +799,7 @@ static HRESULT WINAPI POP3Transport_Connect(IPOP3Transport *iface,
if
(
FAILED
(
hr
))
return
hr
;
init_parser
(
This
,
POP3_USER
,
POP3_NONE
);
init_parser
(
This
,
POP3_USER
);
return
InternetTransport_ReadLine
(
&
This
->
InetTransport
,
POP3Transport_CallbackSendUSERCmd
);
}
...
...
@@ -885,7 +884,7 @@ static HRESULT WINAPI POP3Transport_CommandUSER(IPOP3Transport *iface, LPSTR use
strcat
(
command
,
username
);
strcat
(
command
,
"
\r\n
"
);
init_parser
(
This
,
POP3_USER
,
POP3_NONE
);
init_parser
(
This
,
POP3_USER
);
InternetTransport_DoCommand
(
&
This
->
InetTransport
,
command
,
POP3Transport_CallbackRecvUSERResp
);
HeapFree
(
GetProcessHeap
(),
0
,
command
);
...
...
@@ -908,7 +907,7 @@ static HRESULT WINAPI POP3Transport_CommandPASS(IPOP3Transport *iface, LPSTR pas
strcat
(
command
,
password
);
strcat
(
command
,
"
\r\n
"
);
init_parser
(
This
,
POP3_PASS
,
POP3_NONE
);
init_parser
(
This
,
POP3_PASS
);
InternetTransport_DoCommand
(
&
This
->
InetTransport
,
command
,
POP3Transport_CallbackRecvPASSResp
);
HeapFree
(
GetProcessHeap
(),
0
,
command
);
...
...
@@ -934,7 +933,8 @@ static HRESULT WINAPI POP3Transport_CommandLIST(
}
else
command
=
list_all
;
init_parser
(
This
,
POP3_LIST
,
cmdtype
);
init_parser
(
This
,
POP3_LIST
);
This
->
type
=
cmdtype
;
InternetTransport_DoCommand
(
&
This
->
InetTransport
,
command
,
POP3Transport_CallbackRecvLISTResp
);
if
(
dwPopId
)
HeapFree
(
GetProcessHeap
(),
0
,
command
);
...
...
@@ -956,7 +956,8 @@ static HRESULT WINAPI POP3Transport_CommandTOP(
sprintf
(
command
,
top
,
dwPopId
,
cPreviewLines
);
This
->
preview_lines
=
cPreviewLines
;
init_parser
(
This
,
POP3_TOP
,
cmdtype
);
init_parser
(
This
,
POP3_TOP
);
This
->
type
=
cmdtype
;
InternetTransport_DoCommand
(
&
This
->
InetTransport
,
command
,
POP3Transport_CallbackRecvTOPResp
);
HeapFree
(
GetProcessHeap
(),
0
,
command
);
...
...
@@ -972,7 +973,7 @@ static HRESULT WINAPI POP3Transport_CommandQUIT(IPOP3Transport *iface)
InternetTransport_ChangeStatus
(
&
This
->
InetTransport
,
IXP_DISCONNECTING
);
init_parser
(
This
,
POP3_QUIT
,
POP3_NONE
);
init_parser
(
This
,
POP3_QUIT
);
return
InternetTransport_DoCommand
(
&
This
->
InetTransport
,
command
,
POP3Transport_CallbackRecvQUITResp
);
}
...
...
@@ -983,7 +984,7 @@ static HRESULT WINAPI POP3Transport_CommandSTAT(IPOP3Transport *iface)
TRACE
(
"
\n
"
);
init_parser
(
This
,
POP3_STAT
,
POP3_NONE
);
init_parser
(
This
,
POP3_STAT
);
InternetTransport_DoCommand
(
&
This
->
InetTransport
,
stat
,
POP3Transport_CallbackRecvSTATResp
);
return
S_OK
;
}
...
...
@@ -995,7 +996,7 @@ static HRESULT WINAPI POP3Transport_CommandNOOP(IPOP3Transport *iface)
TRACE
(
"
\n
"
);
init_parser
(
This
,
POP3_NOOP
,
POP3_NONE
);
init_parser
(
This
,
POP3_NOOP
);
InternetTransport_DoCommand
(
&
This
->
InetTransport
,
noop
,
POP3Transport_CallbackRecvNOOPResp
);
return
S_OK
;
}
...
...
@@ -1007,7 +1008,7 @@ static HRESULT WINAPI POP3Transport_CommandRSET(IPOP3Transport *iface)
TRACE
(
"
\n
"
);
init_parser
(
This
,
POP3_RSET
,
POP3_NONE
);
init_parser
(
This
,
POP3_RSET
);
InternetTransport_DoCommand
(
&
This
->
InetTransport
,
rset
,
POP3Transport_CallbackRecvRSETResp
);
return
S_OK
;
}
...
...
@@ -1031,7 +1032,8 @@ static HRESULT WINAPI POP3Transport_CommandUIDL(
}
else
command
=
uidl_all
;
init_parser
(
This
,
POP3_UIDL
,
cmdtype
);
init_parser
(
This
,
POP3_UIDL
);
This
->
type
=
cmdtype
;
InternetTransport_DoCommand
(
&
This
->
InetTransport
,
command
,
POP3Transport_CallbackRecvUIDLResp
);
if
(
dwPopId
)
HeapFree
(
GetProcessHeap
(),
0
,
command
);
...
...
@@ -1052,7 +1054,8 @@ static HRESULT WINAPI POP3Transport_CommandDELE(
if
(
!
(
command
=
HeapAlloc
(
GetProcessHeap
(),
0
,
len
)))
return
S_FALSE
;
sprintf
(
command
,
dele
,
dwPopId
);
init_parser
(
This
,
POP3_DELE
,
cmdtype
);
init_parser
(
This
,
POP3_DELE
);
This
->
type
=
cmdtype
;
InternetTransport_DoCommand
(
&
This
->
InetTransport
,
command
,
POP3Transport_CallbackRecvDELEResp
);
HeapFree
(
GetProcessHeap
(),
0
,
command
);
...
...
@@ -1073,7 +1076,8 @@ static HRESULT WINAPI POP3Transport_CommandRETR(
if
(
!
(
command
=
HeapAlloc
(
GetProcessHeap
(),
0
,
len
)))
return
S_FALSE
;
sprintf
(
command
,
retr
,
dwPopId
);
init_parser
(
This
,
POP3_RETR
,
cmdtype
);
init_parser
(
This
,
POP3_RETR
);
This
->
type
=
cmdtype
;
InternetTransport_DoCommand
(
&
This
->
InetTransport
,
command
,
POP3Transport_CallbackRecvRETRResp
);
HeapFree
(
GetProcessHeap
(),
0
,
command
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment