1. In osrfAppChildInit(): reduce the scope of the attr variable. Don't call
authorscottmk <scottmk@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Thu, 9 Apr 2009 14:42:24 +0000 (14:42 +0000)
committerscottmk <scottmk@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Thu, 9 Apr 2009 14:42:24 +0000 (14:42 +0000)
commitb8e2ec38c18f87347fcbeadade0684f503bb25e5
tree81ae45190df1a961ac5b4d730cb1171cf17ec638
parent41ed1e380063f9385e661e860c91fafc100d46c6
1. In osrfAppChildInit(): reduce the scope of the attr variable.  Don't call
dbi_result_get_field_attribs() unless you're going to use the result.

2. In dbi_result_get_field_attribs(): Eliminate the round trip from string to
number and back to string; just use the string that's already available.

If the string is in a JSON_NUMBER, it's guaranteed to be numeric.  If the
string is in a JSON_STRING, it might not be numeric, and if it isn't, then
PostgreSQL will choke on it.  The old code would silently convert it to zero,
or possibly to some other unintended value.

git-svn-id: svn://svn.open-ils.org/ILS/trunk@12823 dcc99617-32d9-48b4-a31d-7c20da2025e4
Open-ILS/src/c-apps/oils_cstore.c