Aleksey Samsonov wrote: > Viktor TARASOV wrote: > >> my general question is: >> will you agree to have a little bit more of the debug messages in the >> common sources ? >> IMHO, it will facilitate the debugging and the comprehension of the 'how >> it works'. >> > > If it is useful, yes. > > >> I mean, at least, to use more of the log macros ( SC_FUNC_RETURN, >> SC_FUNC_CALLED and SC_TEST_RET) >> instead of simple 'return SC_xxx', >> to use the 'return' macro in the functions that starts from 'call' >> macro, etc. >> > > > Using everywhere these log macros is not reasonable. > It can make the simple code too difficult, overloaded with details. > But if the function is big and with complicated logic, additional > detailed log will be useful. True criterion is common sence. >
I see, thank you, I will try to trust my common sense. >> (Sometimes, in the sources, there is an textual duplicate of the >> existing macros). >> > > What do you want to change and where? > In a fact, I was looking through libopensc/pkcs.c (ex. +365, +525, ..) . >> Does it exists any rule for the assigning of the debug level for debug >> messages ? >> > > I think we have to follow common sence. > In the same direction, some features that we are locally using: Duplicate the 'sc_error' messages as the 'sc_debug' ones with some low level of importance. Sometimes it not evident to find the correspondence . Message time stamp (1 msec resolution for Windows. For Linux it's 1 sec -- was not able to do better in a simple manner) . In the reader logs (for ex. in pcsc_transmit() of reader-pcsc.c) insert the reader's name . It helps. Kind wishes, Viktor Tarasov. > _______________________________________________ > opensc-devel mailing list > opensc-devel@lists.opensc-project.org > http://www.opensc-project.org/mailman/listinfo/opensc-devel > > -- Viktor Tarasov <viktor.tara...@opentrust.com> _______________________________________________ opensc-devel mailing list opensc-devel@lists.opensc-project.org http://www.opensc-project.org/mailman/listinfo/opensc-devel