[ scummvm-Patches-3104630 ] OSYSTEM: Add logging API as proposed by Max on -devel

SourceForge.net noreply at sourceforge.net
Sun Nov 7 15:00:13 CET 2010


Patches item #3104630, was opened at 2010-11-07 15:00
Message generated for change (Tracker Item Submitted) made by lordhoto
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=418822&aid=3104630&group_id=37116

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Johannes Schickel (lordhoto)
Assigned to: Max Horn (fingolfin)
Summary: OSYSTEM: Add logging API as proposed by Max on -devel

Initial Comment:
Hello,

this implements the API described in "PROPOSAL: Removing (f)printf usage".

Most of the changes are done, but it might be noteworthy that I was only able to check the compilation and result on Linux

Only the Symbian port still needs adaption. The Symbian port currently has it's own "FatalError" function which takes a string and displays that as an error message to the user and then quits. I am unsure in how to adapt that to the new API though. Also the Symbian port formerly didn't output any warnings at all as far as I can tell (at least there's some check which only called fputs in case in case __SYMBIAN32__ wasn't defined).

Another bits is that in case there's no g_system setup properly yet debug/warning/error won't output anything at all anymore. This sounds bad, at least in case the backend wants to use those for reporting of initialization problems. I am open for suggestions here.

I also noticed that it seems the SamsungTV backend doesn't have a working "exit" implementation, at least it's replaced by an endless loop. Since when there's no g_system we can't call OSystem::fatalError I had to leave that in ::error.

Last but not least I still had to include some backends headers for the default implemtation of OSystem::logMessage, since it relies on fputs and fflush. I am not sure whether we really want that, on the other hand I miss an good idea on how to avoid that right now though (except with offering no default implementation).

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=418822&aid=3104630&group_id=37116




More information about the Scummvm-tracker mailing list