From cbb2adb8f35dfc11ac58bff6fa56b99f071a76cd Mon Sep 17 00:00:00 2001 From: deva Date: Fri, 15 Aug 2008 12:50:45 +0000 Subject: Fixed compile warning, and removed old reader code. --- server/src/transactionparser.cc | 18 ++---------------- 1 file changed, 2 insertions(+), 16 deletions(-) (limited to 'server/src') diff --git a/server/src/transactionparser.cc b/server/src/transactionparser.cc index 3d3024c..1dbeb39 100644 --- a/server/src/transactionparser.cc +++ b/server/src/transactionparser.cc @@ -79,20 +79,6 @@ int TransactionParser::readData(char *data, size_t size) { printf("readData is not uasble with transaction parser!.\nUse parse(std::string) instead.\n"); return 0; -/* - if(done) return 0; - - int ret; - - // while((ret = socket->read(data, size, 1000)) == 0) { } - - if(ret == -1) { - printf("Transaction parser was interrupted.\n"); - return 0; - } - - return ret; -*/ } bool TransactionParser::parse(std::string data) @@ -103,8 +89,8 @@ bool TransactionParser::parse(std::string data) } if(done) { - if(! XML_Parse(p, "", 0, true) ) { - parseError("", 0, XML_ErrorString(XML_GetErrorCode(p)), (int)XML_GetCurrentLineNumber(p)); + if(! XML_Parse(p, (char*)data.c_str(), 0, true) ) { + parseError((char*)data.c_str(), 0, XML_ErrorString(XML_GetErrorCode(p)), (int)XML_GetCurrentLineNumber(p)); return false; } } -- cgit v1.2.3