aboutsummaryrefslogtreecommitdiffstats
path: root/src/sccp_user.c
diff options
context:
space:
mode:
authorPhilipp Maier <pmaier@sysmocom.de>2017-08-11 11:30:26 +0200
committerPhilipp Maier <pmaier@sysmocom.de>2017-08-11 11:30:26 +0200
commiteafa10dd17ea1090d6e712e286b065a74c2baecb (patch)
treef3c75ec0a5d471a7e9762339bd1ab25037e06d9e /src/sccp_user.c
parent130c6808544e9b48f4742e2ef4ca5ca30d2b1425 (diff)
sccp: fix handling of default IP addresses in osmo_sccp_simple_client()
When the default IP addresses (remote or local) the respective struct value should be set to NULL. Fix wrong ?:-notation. Change-Id: I312caf9d54cedb02034e4ef88fdd2e6ad9ca1c34
Diffstat (limited to 'src/sccp_user.c')
-rw-r--r--src/sccp_user.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/sccp_user.c b/src/sccp_user.c
index 9116b60..4e28aa0 100644
--- a/src/sccp_user.c
+++ b/src/sccp_user.c
@@ -404,10 +404,10 @@ osmo_sccp_simple_client_on_ss7_id(void *ctx, uint32_t ss7_id, const char *name,
goto out_rt;
asp_created = true;
- default_local_ip ? asp->cfg.local.host =
- talloc_strdup(asp, default_local_ip) : NULL;
- default_remote_ip ? asp->cfg.remote.host =
- talloc_strdup(asp, default_remote_ip) : NULL;
+ asp->cfg.local.host =
+ default_local_ip ? asp->cfg.local.host : NULL;
+ asp->cfg.remote.host =
+ default_remote_ip ? asp->cfg.remote.host : NULL;
osmo_ss7_as_add_asp(as, asp->cfg.name);
}