strongswan.org
Wiki/Project Management
Downloads
Gitweb
projects
/
strongswan.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
061c95b
)
Fixed handling of IKE_SAs without a virtual IP in farp plugin
author
Martin Willi
<martin@revosec.ch>
Tue, 30 Mar 2010 08:24:47 +0000
(10:24 +0200)
committer
Martin Willi
<martin@revosec.ch>
Tue, 30 Mar 2010 08:24:47 +0000
(10:24 +0200)
src/libcharon/plugins/farp/farp_listener.c
patch
|
blob
|
history
diff --git
a/src/libcharon/plugins/farp/farp_listener.c
b/src/libcharon/plugins/farp/farp_listener.c
index
3875c1f
..
8eed497
100644
(file)
--- a/
src/libcharon/plugins/farp/farp_listener.c
+++ b/
src/libcharon/plugins/farp/farp_listener.c
@@
-87,11
+87,14
@@
METHOD(listener_t, message_hook, bool,
host_t *ip;
ip = ike_sa->get_virtual_ip(ike_sa, FALSE);
- ip = ip->clone(ip);
- this->lock->write_lock(this->lock);
- ip = this->ips->put(this->ips, ip, ip);
- this->lock->unlock(this->lock);
- DESTROY_IF(ip);
+ if (ip)
+ {
+ ip = ip->clone(ip);
+ this->lock->write_lock(this->lock);
+ ip = this->ips->put(this->ips, ip, ip);
+ this->lock->unlock(this->lock);
+ DESTROY_IF(ip);
+ }
}
return TRUE;
}