summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/ccapi/lib/ccapi_ccache_iterator.c19
-rw-r--r--src/ccapi/lib/ccapi_credentials_iterator.c12
2 files changed, 31 insertions, 0 deletions
diff --git a/src/ccapi/lib/ccapi_ccache_iterator.c b/src/ccapi/lib/ccapi_ccache_iterator.c
index 26162af32..1d4dd6c55 100644
--- a/src/ccapi/lib/ccapi_ccache_iterator.c
+++ b/src/ccapi/lib/ccapi_ccache_iterator.c
@@ -125,6 +125,25 @@ cc_int32 ccapi_ccache_iterator_release (cc_ccache_iterator_t io_ccache_iterator)
if (!io_ccache_iterator) { err = ccErrBadParam; }
if (!err) {
+ cc_uint32 initialized = 0;
+
+ err = cci_identifier_is_initialized (ccache_iterator->identifier,
+ &initialized);
+
+ if (!err && initialized) {
+ err = cci_ipc_send (cci_ccache_iterator_release_msg_id,
+ ccache_iterator->identifier,
+ NULL,
+ NULL);
+ if (err) {
+ cci_debug_printf ("%s: cci_ipc_send failed with error %d",
+ __FUNCTION__, err);
+ err = ccNoError;
+ }
+ }
+ }
+
+ if (!err) {
free ((char *) ccache_iterator->functions);
cci_identifier_release (ccache_iterator->identifier);
free (ccache_iterator->saved_ccache_name);
diff --git a/src/ccapi/lib/ccapi_credentials_iterator.c b/src/ccapi/lib/ccapi_credentials_iterator.c
index 4f38d0745..8d667acc4 100644
--- a/src/ccapi/lib/ccapi_credentials_iterator.c
+++ b/src/ccapi/lib/ccapi_credentials_iterator.c
@@ -125,6 +125,18 @@ cc_int32 ccapi_credentials_iterator_release (cc_credentials_iterator_t io_creden
if (!io_credentials_iterator) { err = ccErrBadParam; }
if (!err) {
+ err = cci_ipc_send (cci_credentials_iterator_next_msg_id,
+ credentials_iterator->identifier,
+ NULL,
+ NULL);
+ if (err) {
+ cci_debug_printf ("%s: cci_ipc_send failed with error %d",
+ __FUNCTION__, err);
+ err = ccNoError;
+ }
+ }
+
+ if (!err) {
free ((char *) credentials_iterator->functions);
cci_identifier_release (credentials_iterator->identifier);
free (credentials_iterator);