[Freeciv-Dev] patch: server console improvement
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
This patch makes some improvements to the server console. It is based
in parts on a patch by Per Mathisen <permath@xxxxxxxxxxx>, but with a
somewhat different approach to interact better with the freelog() system.
Features:
- Prints a new prompt when required, but without a new one every turn.
(Although in some cases there might still be a few surplus prompts.)
Doesn't necessarily print a new prompt for each log message:
turns prompt "on" when waiting for input, and "off" whe processing
input, either from console or clients, or during being/end-turn.
Then back on again when ready for new input.
- Interacts nicely with the freelog() system, by registering
a function to be called by freelog().
- rfcstyle option to generate server console output in a
more parser-friendly format.
A feature which is missing, is that there should be a logging option
to print all duplicate messages individually, rather than as
"last message repeated X times", since this may be useful for
debugging (immediate output) and rfcstyle.
Partially implemented is the ability to log to the console and to
a file. (freelog() can now do this, but the server code doesn't
use it.) Actually, it would probably be good if the log levels for
console/file could be set independently (eg, LOG_NORMAL messages
to console, all messages including LOG_DEBUG to file). Also, the
logging configuration should be able to be set via _server_commands_!
If no problems are raised with this patch, I will check it in, and
then more improvements (such as the above) can be made from there.
(Note this patch should ideally be used with a very recent cvs
version, where I've changed some debug printfs.)
Regards,
-- David
console_d3.diff.gz
Description: GNU Zip compressed data
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Freeciv-Dev] patch: server console improvement,
David Pfitzner <=
|
|