From 7360a36eadf8be9c234e8d9d4121c7027597c451 Mon Sep 17 00:00:00 2001 From: Holger Hans Peter Freyther Date: Sun, 1 Aug 2010 04:06:04 +0800 Subject: sccp: Copy out pointers to the GTI into the parsed structure.. --- include/sccp/sccp.h | 4 ++++ src/sccp/sccp.c | 6 ++++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/include/sccp/sccp.h b/include/sccp/sccp.h index 6305704..fd468c5 100644 --- a/include/sccp/sccp.h +++ b/include/sccp/sccp.h @@ -72,6 +72,10 @@ struct sccp_address { struct sccp_called_party_address address; uint8_t ssn; uint8_t poi[2]; + + uint8_t gti_ind; + uint8_t *gti_data; + int gti_len; }; struct sccp_optional_data { diff --git a/src/sccp/sccp.c b/src/sccp/sccp.c index 12addde..9965c64 100644 --- a/src/sccp/sccp.c +++ b/src/sccp/sccp.c @@ -143,9 +143,11 @@ static int copy_address(struct sccp_address *addr, uint8_t offset, struct msgb * read += 1; } + /* copy the GTI over */ if (party->global_title_indicator) { - LOGP(DSCCP, LOGL_ERROR, "GTI not supported %u\n", *(uint8_t *)party); - return -1; + addr->gti_ind = party->global_title_indicator; + addr->gti_len = length - read - 1; + addr->gti_data = &party->data[read]; } addr->address = *party; -- cgit v1.2.3