]> git.evergreen-ils.org Git - OpenSRF.git/commit
Patch from Scott McKellar with minor adjustments:
authormiker <miker@9efc2488-bf62-4759-914b-345cdb29e865>
Tue, 12 Jun 2007 01:10:05 +0000 (01:10 +0000)
committermiker <miker@9efc2488-bf62-4759-914b-345cdb29e865>
Tue, 12 Jun 2007 01:10:05 +0000 (01:10 +0000)
commite211b2be63b2b70e6fdde21a129f69ddc39a47f2
tree78c23ddbfd8b9636724ae0abf17b579c0a9f029c
parentf6768223754011f924982e770757d57a8a5a55de
Patch from Scott McKellar with minor adjustments:

1. In an earlier patch to osrf_settings_host_value_object(), we
contrived to abort the program deliberately instead of crashing with
a segmentation violation.  The current patch applies the same
treatment to the similar function osrf_settings_host_value(),
although I don't know that anyone has ever reported a problem at
this spot.  I rearranged the error message a bit so that it would
be distinct from the other one.

2. If the config pointer is null, it's because osrf_settings_retrieve()
was unable to populate it, or was never called.  There are two ways
it might fail: it might not get an osrf_message from
osrf_app_session_request_recv(), or the osrf_message it gets might
not have the _result_content member populated.  I added a couple of
log messages to distinguish between these possibilities. Maybe they
will make diagnosis easier.

3. The latter change also plugs a small memory leak.  If we get an
osrf_message but it has no _result_content, the present code neglects
to free the osrf_message.

git-svn-id: svn://svn.open-ils.org/OpenSRF/trunk@939 9efc2488-bf62-4759-914b-345cdb29e865
src/libstack/osrf_settings.c