Two patches from Scott McKellar:
authorerickson <erickson@9efc2488-bf62-4759-914b-345cdb29e865>
Wed, 26 Nov 2008 17:56:42 +0000 (17:56 +0000)
committererickson <erickson@9efc2488-bf62-4759-914b-345cdb29e865>
Wed, 26 Nov 2008 17:56:42 +0000 (17:56 +0000)
In some earlier patches I eliminated the old osrf_app_client_session_init
function in favor of its camel-case equivalent.  Unfortunately I didn't
notice that the new function now puts the old function's name into an
error message.  Here's the fix for that little oversight.

---

These patches replace a couple of deprecated identifiers with their
camel-case equivalents:

    osrf_message ==> osrfMessage
    string_array ==> osrfStringArray

git-svn-id: svn://svn.open-ils.org/OpenSRF/trunk@1514 9efc2488-bf62-4759-914b-345cdb29e865

include/opensrf/osrf_app_session.h
src/libopensrf/osrf_app_session.c
src/srfsh/srfsh.c

index 4c535ba..b1ad262 100644 (file)
@@ -31,9 +31,9 @@ struct osrf_app_request_struct {
        /** True if we have received a 'request complete' message from our request */
        int complete;
        /** Our original request payload */
-       osrf_message* payload; 
+       osrfMessage* payload;
        /** List of responses to our request */
-       osrf_message* result;
+       osrfMessage* result;
 
        /* if set to true, then a call that is waiting on a response, will reset the 
                timeout and set this variable back to false */
@@ -113,7 +113,7 @@ osrfAppSession* osrf_app_session_find_session( const char* session_id );
   */
 int osrfAppSessionMakeRequest(
                osrfAppSession* session, const jsonObject* params,
-               const char* method_name, int protocol, string_array* param_strings);
+               const char* method_name, int protocol, osrfStringArray* param_strings);
 
 /** Sets the given request to complete state */
 void osrf_app_session_set_complete( osrfAppSession* session, int request_id );
@@ -122,7 +122,7 @@ void osrf_app_session_set_complete( osrfAppSession* session, int request_id );
 int osrf_app_session_request_complete( const osrfAppSession* session, int request_id );
 
 /** Does a recv call on the given request */
-osrf_message* osrfAppSessionRequestRecv(
+osrfMessage* osrfAppSessionRequestRecv(
                osrfAppSession* session, int request_id, int timeout );
 
 /** Removes the request from the request set and frees the reqest */
@@ -140,7 +140,7 @@ void osrf_app_session_set_remote( osrfAppSession* session, const char* remote_id
 /** pushes the given message into the result list of the app_request
   * whose request_id matches the messages thread_trace 
   */
-int osrf_app_session_push_queue( osrfAppSession*, osrf_message* msg );
+int osrf_app_session_push_queue( osrfAppSession*, osrfMessage* msg );
 
 /** Attempts to connect to the remote service. Returns 1 on successful 
   * connection, 0 otherwise.
index 0b274f7..c0669e9 100644 (file)
@@ -220,7 +220,7 @@ static void _osrf_app_session_push_session( osrfAppSession* session ) {
 osrfAppSession* osrfAppSessionClientInit( const char* remote_service ) {
 
        if (!remote_service) {
-               osrfLogWarning( OSRF_LOG_MARK, "No remote service specified in osrf_app_client_session_init");
+               osrfLogWarning( OSRF_LOG_MARK, "No remote service specified in osrfAppSessionClientInit");
                return NULL;
        }
 
index 1d4129c..e468849 100644 (file)
@@ -38,7 +38,7 @@ static int raw_print = 0;
 static transport_client* client = NULL; 
 
 /* the last result we received */
-static osrf_message* last_result = NULL;
+static osrfMessage* last_result = NULL;
 
 /* functions */
 static int parse_request( char* request );
@@ -583,7 +583,7 @@ int send_request( char* server,
        int req_id = osrfAppSessionMakeRequest( session, params, method, 1, NULL );
        jsonObjectFree(params);
 
-       osrf_message* omsg = osrfAppSessionRequestRecv( session, req_id, recv_timeout );
+       osrfMessage* omsg = osrfAppSessionRequestRecv( session, req_id, recv_timeout );
 
        if(!omsg) 
                printf("\nReceived no data from server\n");
@@ -868,7 +868,7 @@ static int do_math( int count, int style ) {
 
                        double start = get_timestamp_millis();
                        int req_id = osrfAppSessionMakeRequest( session, params, methods[j], 1, NULL );
-                       osrf_message* omsg = osrfAppSessionRequestRecv( session, req_id, 5 );
+                       osrfMessage* omsg = osrfAppSessionRequestRecv( session, req_id, 5 );
                        double end = get_timestamp_millis();
 
                        times[(4*i) + j] = end - start;