summaryrefslogtreecommitdiffstats
path: root/ipsec-tools/src/libipsec/policy_parse.y
diff options
context:
space:
mode:
Diffstat (limited to 'ipsec-tools/src/libipsec/policy_parse.y')
-rw-r--r--ipsec-tools/src/libipsec/policy_parse.y15
1 files changed, 15 insertions, 0 deletions
diff --git a/ipsec-tools/src/libipsec/policy_parse.y b/ipsec-tools/src/libipsec/policy_parse.y
index 321f4f06..a7cdca82 100644
--- a/ipsec-tools/src/libipsec/policy_parse.y
+++ b/ipsec-tools/src/libipsec/policy_parse.y
@@ -63,6 +63,9 @@
*/
%{
+#ifdef __rtems__
+#include <machine/rtems-bsd-user-space.h>
+#endif /* __rtems__ */
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
@@ -600,6 +603,10 @@ policy_parse(msg, msglen)
error = yyparse(); /* it must be set errcode. */
__policy__strbuffer__free__();
+ #ifdef __rtems__
+ /* This frees the p_src and p_dst buffers. */
+ policy_parse_request_init();
+ #endif /* __rtems__ */
if (error) {
if (pbuf != NULL)
@@ -632,3 +639,11 @@ ipsec_set_policy(msg, msglen)
__ipsec_errcode = EIPSEC_NO_ERROR;
return policy;
}
+#ifdef __rtems__
+
+void
+ipsec_free_policy(ipsec_policy_t buf)
+{
+ free(buf);
+}
+#endif /* __rtems__ */