summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHolger Hans Peter Freyther <zecke@selfish.org>2010-08-01 04:06:04 +0800
committerHolger Hans Peter Freyther <zecke@selfish.org>2010-08-01 04:57:41 +0800
commit7360a36eadf8be9c234e8d9d4121c7027597c451 (patch)
tree98ede225ff3d5b7ffefbc4c98af57ad22d6a9ee6
parent9aa8c8bb35f4c5fe78f514f9ecece20f26cea808 (diff)
sccp: Copy out pointers to the GTI into the parsed structure..
-rw-r--r--include/sccp/sccp.h4
-rw-r--r--src/sccp/sccp.c6
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;