[Opensrf-commits] r1957 - trunk/src/router (scottmk)
svn at svn.open-ils.org
svn at svn.open-ils.org
Mon Jun 14 14:31:36 EDT 2010
Author: scottmk
Date: 2010-06-14 14:31:32 -0400 (Mon, 14 Jun 2010)
New Revision: 1957
Modified:
trunk/src/router/osrf_router.c
Log:
When traversing a list of osrfMessages: don't free the messages.
The list owns them. Instead, get the list to free them when
you're done, by calling osrfListClear().
M src/router/osrf_router.c
Modified: trunk/src/router/osrf_router.c
===================================================================
--- trunk/src/router/osrf_router.c 2010-05-23 22:26:09 UTC (rev 1956)
+++ trunk/src/router/osrf_router.c 2010-06-14 18:31:32 UTC (rev 1957)
@@ -794,7 +794,7 @@
// Translate the JSON into a list of osrfMessages
router->message_list = osrfMessageDeserialize( msg->body, router->message_list );
- osrfMessage* omsg = NULL;
+ const osrfMessage* omsg = NULL;
// Process each osrfMessage
int i;
@@ -816,10 +816,9 @@
default:
break;
}
-
- osrfMessageFree( omsg );
}
}
+ osrfListClear( router->message_list );
return;
}
More information about the opensrf-commits
mailing list