[strongSwan-dev] rekeying, null pointer access check patch.

Bharat Bhushan bharat.76 at gmail.com
Tue Aug 16 09:35:20 CEST 2011


Hi Andreas:

Null pointer check is added.


diff -Naur strongswan-4.5.0{.orig,}/src/libcharon/sa/tasks/child_rekey.c
--- strongswan-4.5.0.orig/src/libcharon/sa/tasks/child_rekey.c	2010-09-06
15:16:15.000000000 +0530
+++ strongswan-4.5.0/src/libcharon/sa/tasks/child_rekey.c	2011-08-16
12:37:21.268333000 +0530
@@ -253,7 +253,10 @@
 			{
 				/* disable close action for the redundand child */
 				child_sa = other->child_create->get_child(other->child_create);
-				child_sa->set_close_action(child_sa, ACTION_NONE);
+				if (child_sa)
+				{
+					child_sa->set_close_action(child_sa, ACTION_NONE);
+				}
 			}
 		}
 		else

Regards,
Bharat




More information about the Dev mailing list