mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-16 23:05:42 +00:00
add ability to pass results of commands back to front end code so the fe can handle errors, bug 20071 r=cavin, sr=sspitzer
This commit is contained in:
parent
b1308fc696
commit
0fd4bbe14f
@ -693,7 +693,24 @@ void nsImapServerResponseParser::response_data()
|
||||
else if (!PL_strcasecmp(fNextToken, "XAOL-OPTION"))
|
||||
skip_to_CRLF();
|
||||
else
|
||||
SetSyntaxError(PR_TRUE);
|
||||
{
|
||||
// check if custom command
|
||||
nsXPIDLCString customCommand;
|
||||
fServerConnection.GetCurrentUrl()->GetCommand(getter_Copies(customCommand));
|
||||
if (customCommand.Equals(fNextToken))
|
||||
{
|
||||
nsCAutoString customCommandResponse;
|
||||
while (Connected() && !at_end_of_line())
|
||||
{
|
||||
fNextToken = GetNextToken();
|
||||
customCommandResponse.Append(fNextToken);
|
||||
customCommandResponse.Append(" ");
|
||||
}
|
||||
fServerConnection.GetCurrentUrl()->SetCustomCommandResult(customCommandResponse.get());
|
||||
}
|
||||
else
|
||||
SetSyntaxError(PR_TRUE);
|
||||
}
|
||||
break;
|
||||
default:
|
||||
if (IsNumericString(fNextToken))
|
||||
|
Loading…
Reference in New Issue
Block a user