fixed memory leak in the IETF standard error handling
authorAndreas Steffen <andreas.steffen@strongswan.org>
Thu, 12 Jul 2012 11:38:44 +0000 (13:38 +0200)
committerAndreas Steffen <andreas.steffen@strongswan.org>
Thu, 12 Jul 2012 19:26:18 +0000 (21:26 +0200)
src/libimcv/pa_tnc/pa_tnc_msg.c

index 4c44693..63ad94e 100644 (file)
@@ -382,8 +382,9 @@ METHOD(pa_tnc_msg_t, process_ietf_std_errors, bool,
                                        break;
                        }
 
-                       /* remove the processed IETF standard error attribute */
+                       /* remove and delete the processed IETF standard error attribute */
                        this->attributes->remove_at(this->attributes, enumerator);
+                       attr->destroy(attr);
                        fatal_error = TRUE;
                }
        }