ca_replace_printf_handler should supply a user private pointer
Bug #541271 reported by
Jeff Hill
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
EPICS Base |
Won't Fix
|
Wishlist
|
mdavidsaver |
Bug Description
ca_replace_
Original Mantis Bug: mantis-236
http://
To post a comment you must log in.
I notice on browsing CA that the function that gets redirected by printf_ handler is little used. The default is
ca_replace_
errlogVprintf. However, it is much more common to use errlogVPrintf
or errlogPrintf directly, which does not get redirected. It would
seem good to make a more consistent policy, perhaps eliminating it
entirely.
BTW I notice the CTOR for ca_client_context initializes pVPrintFunc to printf_ handler (actually context: :replaceErrlogH andler) sets it to epicsVprintf if
errlogVprintf, whereas ca_replace_
ca_client_
the incoming argument is NULL. They are the same via errlog.h.
Following this sort of spaghetti is tedious when you are trying to
trace code. It could all be cleaned up.