namespace
 {
 
-const std::string::size_type MAX_XML_CHUNK_LENGTH = 2048;
-
 struct ReadState
 {
     bool final;
 {
 STG::ENCRYPT_STREAM stream(password, TxCrypto, this);
 stream.Put(text.c_str(), text.length() + 1, true);
-if (!stream.isOk())
+if (!stream.IsOk())
     {
     errorMsg = SEND_DATA_ERROR;
     return st_send_fail;
         return st_recv_fail;
         }
     stream.Put(buffer, res, res == 0);
-    if (!stream.isOk())
+    if (!stream.IsOk())
         return st_xml_parse_error;
     }