On Wed, 2008-11-05 at 11:27 +0300, Dmitry Goncharov wrote: > I considered providing a patch, but finally decided not to (because > the library maintainers dont seem to be willing to apply patches) and > used the LD_PRELOAD method described above.
We apply the patches immediately which solves critical issues. The patches you have sent may be critical fixes for you but may not be for the community. Actually these patches will be applied when developers get time to fix Jiras, most probably for a major release. So we always encourage community to send patches, because at some time they will be applied if they improve Axis2/C code base. > > BR, Dmitry > > > Haszlakiewicz, Eric wrote: > > I have a need to use axis within an existing system that has it's own > > ways of opening/closing/rotating logs and I've found the existing axis > > log interfaces to be a bit lacking. I have some patches, but before I > > submit a issue in jira I wanted to run the changes past some people to > > see if what I'm doing makes sense. > > > > There are two issues that I'm fixing: > > 1) the log functions don't keep track of whether the filedescriptor > > was opened by axis, so if you create a env using axutil_env_create() it > > ends up closing stderr when you try to set a new log file. > > > > 2) There's no way to tell axis to log to a filedescriptor rather than > > to a named file. > > > > I added two functions to axutil_log_default.h: > > > > One to create a axutil_log_t using an existing FILE * as returned from > > fopen: > > AXIS2_EXTERN axutil_log_t *AXIS2_CALL > > axutil_log_create_fp( > > axutil_allocator_t *allocator, > > axutil_log_ops_t *ops, > > void *stream, > > int close_stream); > > I also factored out a static axutil_log_create_common() function, which > > is used by both axutil_log_create_fp() and the original > > axutil_log_create(). > > > > And, one to switch the FILE pointer on an existing log structure: > > AXIS2_EXTERN void AXIS2_CALL > > axutil_log_set_stream( > > axutil_allocator_t *allocator, > > axutil_log_t *log, > > void *stream, > > int close_stream); > > > > In both of these, the close_stream flag indicates whether axis is > > allowed to close the stream when a new one is set or when the log > > structure is cleaned up. That is stored in a new field in the > > axutil_log_impl structure. > > > > Does this seem reasonable? Should I send the full patch to the list? > > > > eric > > > > (btw, I created a couple of other jira issues (AXIS2C-1271, AXIS2C-1280) > > w/ patches attached. About how long can I expect before they are > > applied?) > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]