`all session data' modes, without completely mauling the performance, by
fflush()ing once per term_out(). If anyone complains I suppose we can
make this optional.
git-svn-id: svn://svn.tartarus.org/sgt/putty@4445
cda61777-01e9-0310-a592-
d414129be87e
}
/*
+ * Flush any open log file.
+ */
+void logflush(void *handle) {
+ struct LogContext *ctx = (struct LogContext *)handle;
+ if (ctx->cfg.logtype > 0)
+ if (ctx->lgfp)
+ fflush(ctx->lgfp);
+}
+
+/*
* Log an Event Log entry. Used in SSH packet logging mode; this is
* also as convenient a place as any to put the output of Event Log
* entries to stderr when a command-line tool is in verbose mode.
void logfopen(void *logctx);
void logfclose(void *logctx);
void logtraffic(void *logctx, unsigned char c, int logmode);
+void logflush(void *logctx);
void log_eventlog(void *logctx, const char *string);
enum { PKT_INCOMING, PKT_OUTGOING };
void log_packet(void *logctx, int direction, int type,
}
term_print_flush(term);
+ logflush(term->logctx);
}
#if 0