libosmo-sccp/src
Neels Hofmeyr b711e14504 add OSMO_SS7_PC_INVALID, add osmo_ss7_pc_is_valid()
Introduce OSMO_SS7_PC_INVALID to mark an unset point code.

Add static osmo_ss7_pc_is_valid() (name matches schema of
osmo_ss7_pc_is_local()).

In osmo_ss7_pointcode_print(), return "(no PC)" if !osmo_ss7_pc_is_valid(), for
convenient printing of any PC state.

Subsequent patches will use this for
osmo_ss7_instance (I7f0f0c89b7335d9da24161bfac8234be214ca00c)
as well as osmo_sccp_user (I8684c9b559712072c772012890bbf7efa7c8eb35).

Rationale:

Currently, in osmo_ss7_vty.c we had "if (inst->cfg.primary_pc)" suggesting 0 is
invalid, but in struct osmo_sccp_user we have flag pc_valid suggesting 0 is
indeed valid. All known point code formats are <= 24bit, so we can easily use
0xffffffff as indicator for an unset PC, which removes the need to remember to
set a second field for validity and keeps the structs nice and lean.

Change-Id: Ib5715bf03a4de7713a7a809dfd821c700255ba8c
2017-08-09 13:53:26 +02:00
..
Makefile.am Fix debian builds 2017-04-25 13:40:12 +02:00
ipa.c Fix debian builds 2017-04-25 13:40:12 +02:00
m3ua.c add/tweak various logging to help figure out complex routing 2017-06-25 22:35:01 +02:00
mtp_pcap.c mtp: Add the MTP Level3 code to the SCCP repoistory 2010-08-01 17:01:26 +08:00
osmo_ss7.c add OSMO_SS7_PC_INVALID, add osmo_ss7_pc_is_valid() 2017-08-09 13:53:26 +02:00
osmo_ss7_hmrt.c add/tweak various logging to help figure out complex routing 2017-06-25 22:35:01 +02:00
osmo_ss7_vty.c osmo_ss7_vty_init: ensure a talloc ctx is set by user 2017-08-07 16:04:39 +02:00
sccp.c NULL safety: sccp_create_sccp_addr: copy only non-NULL sock->gti 2016-12-11 21:24:59 +01:00
sccp2sua.c SUA-to-SCCP: Fix use of Called/Calling vs. Src/Dest Address 2017-05-04 09:07:21 +02:00
sccp_helpers.c add osmo_sccp_addr_set_ssn() 2017-08-07 16:04:39 +02:00
sccp_internal.h SCCP: Add VTY interface for SCCP 2017-04-14 20:25:50 +02:00
sccp_sap.c Add a default layer manager using RKM to register PC with SG 2017-04-13 18:05:13 +02:00
sccp_sclc.c sclc_rx_cldr(): Don't try to dereference user data_ie without check 2017-04-27 12:09:29 +02:00
sccp_scoc.c sccp_scoc: Fix compilation warning and leave a pragma message 2017-07-08 10:46:31 +00:00
sccp_scrc.c gen_mtp_transfer_req_xua(): add addr to error log for missing DPC 2017-06-25 22:35:05 +02:00
sccp_user.c sccp: add function to check sccp addresses 2017-08-09 09:53:35 +00:00
sccp_vty.c SCCP: Add VTY interface for SCCP 2017-04-14 20:25:50 +02:00
sua.c SUA: Make sure to reject unknown CO message types 2017-04-17 10:33:10 +02:00
xua_as_fsm.c Add IPA/SCCPlite support as SIGTRAN alternative 2017-04-18 10:08:25 +00:00
xua_as_fsm.h SUA/M3UA: Implement T(r) recovery timer of Application Server FSM 2017-04-14 22:48:41 +02:00
xua_asp_fsm.c Address some negative integer handling issues 2017-04-27 10:21:42 +02:00
xua_asp_fsm.h Add IPA/SCCPlite support as SIGTRAN alternative 2017-04-18 10:08:25 +00:00
xua_default_lm_fsm.c xua: fix possible memory leak in seems osmo_ss7_asp_use_default_lm() 2017-07-22 09:08:13 +00:00
xua_internal.h xua_internal.h: Add missing functions required by xua_test 2017-06-22 06:23:04 +00:00
xua_msg.c xua_msg: Add xua_from_nested() helper function for nested IEs 2017-04-10 11:48:35 +02:00
xua_rkm.c xua_rkm: Fix handling of RK Registration with multiple Routing Keys 2017-04-27 10:45:09 +02:00