bool FileBasedAGSDebugger::SendMessageToEditor(const char *message) { while (exists(SENT_MESSAGE_FILE_NAME)) { platform->YieldCPU(); } DataStream *out = Common::File::CreateFile(SENT_MESSAGE_FILE_NAME); // CHECKME: originally the file was opened as "wb" for some reason, // which means the message should be written as a binary array; // or shouldn't it? out->Write(message, strlen(message)); delete out; return true; }
void FlushBuffer() { strm->Write(buffer,bufSize); bufSize = 0; }