コード例 #1
0
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;
}
コード例 #2
0
ファイル: tga_image_decoder.cpp プロジェクト: dtozik/GHL
 void FlushBuffer() {
     strm->Write(buffer,bufSize);
     bufSize = 0;
 }