mirror of https://github.com/aria2/aria2
2009-05-15 Tatsuhiro Tsujikawa <t-tujikawa@users.sourceforge.net>
Defined MSG_CANNOT_PARSE_XML_RPC_REQUEST * src/ExpatXmlRpcRequestProcessor.cc * src/Xml2XmlRpcRequestProcessor.cc * src/message.hpull/1/head
parent
389866621f
commit
ee75995198
|
@ -1,3 +1,10 @@
|
|||
2009-05-15 Tatsuhiro Tsujikawa <t-tujikawa@users.sourceforge.net>
|
||||
|
||||
Defined MSG_CANNOT_PARSE_XML_RPC_REQUEST
|
||||
* src/ExpatXmlRpcRequestProcessor.cc
|
||||
* src/Xml2XmlRpcRequestProcessor.cc
|
||||
* src/message.h
|
||||
|
||||
2009-05-15 Tatsuhiro Tsujikawa <t-tujikawa@users.sourceforge.net>
|
||||
|
||||
Defined const BDEs to avoid duplicate instantiation.
|
||||
|
|
|
@ -41,6 +41,7 @@
|
|||
#include "XmlRpcRequestParserStateMachine.h"
|
||||
#include "Util.h"
|
||||
#include "DlAbortEx.h"
|
||||
#include "message.h"
|
||||
|
||||
namespace aria2 {
|
||||
|
||||
|
@ -111,7 +112,7 @@ XmlRpcRequestProcessor::parseMemory(const std::string& xml)
|
|||
XML_ParserFree(parser);
|
||||
|
||||
if(r == XML_STATUS_ERROR) {
|
||||
throw DlAbortEx("Failed to parse xml-rpc request.");
|
||||
throw DlAbortEx(MSG_CANNOT_PARSE_XML_RPC_REQUEST);
|
||||
}
|
||||
return XmlRpcRequest(_stm->getMethodName(), _stm->getCurrentFrameValue());
|
||||
}
|
||||
|
|
|
@ -41,6 +41,7 @@
|
|||
#include "XmlRpcRequestParserStateMachine.h"
|
||||
#include "Util.h"
|
||||
#include "DlAbortEx.h"
|
||||
#include "message.h"
|
||||
|
||||
namespace aria2 {
|
||||
|
||||
|
@ -140,7 +141,7 @@ XmlRpcRequestProcessor::parseMemory(const std::string& xml)
|
|||
int r = xmlSAXUserParseMemory(&mySAXHandler, sessionData.get(),
|
||||
xml.data(), xml.size());
|
||||
if(r != 0) {
|
||||
throw DlAbortEx("Failed to parse xml-rpc request.");
|
||||
throw DlAbortEx(MSG_CANNOT_PARSE_XML_RPC_REQUEST);
|
||||
}
|
||||
return XmlRpcRequest(_stm->getMethodName(), _stm->getCurrentFrameValue());
|
||||
}
|
||||
|
|
|
@ -171,6 +171,7 @@
|
|||
#define MSG_NOT_TORRENT_METALINK _("This file is neither Torrent nor Metalink"\
|
||||
" file. Skipping.")
|
||||
#define MSG_GID_NOT_PROVIDED "GID is not provided."
|
||||
#define MSG_CANNOT_PARSE_XML_RPC_REQUEST "Failed to parse xml-rpc request."
|
||||
|
||||
#define EX_TIME_OUT _("Timeout.")
|
||||
#define EX_INVALID_CHUNK_SIZE _("Invalid chunk size.")
|
||||
|
|
Loading…
Reference in New Issue