void SpamAssassinClient::OnConnected() { // We'll handle all incoming data as binary. SetReceiveBinary(true); message_size_ = FileUtilities::FileSize(message_file_); EnqueueWrite("PROCESS SPAMC/1.2\r\n"); //LOG_DEBUG("SENT: PROCESS SPAMC/1.2"); String sConLen; sConLen.Format(_T("Content-length: %d\r\n"), message_size_); EnqueueWrite(sConLen); EnqueueWrite("\r\n"); SendFileContents_(message_file_); }
void SpamAssassinClient::OnConnected() { // We'll handle all incoming data as binary. SetReceiveBinary(true); message_size_ = FileUtilities::FileSize(message_file_); SendData("PROCESS SPAMC/1.2\r\n"); //LOG_DEBUG("SENT: PROCESS SPAMC/1.2"); String sConLen; sConLen.Format(_T("Content-length: %d\r\n"), message_size_); SendData(sConLen); /*sConLen.Format(_T("Sent: Content-length: %d"), message_size_); LOG_DEBUG(sConLen);*/ //Future feature, per user scanning. SendData("User: "******"\r\n"); SendFileContents_(message_file_); }