diff options
author | Holger Hans Peter Freyther <zecke@selfish.org> | 2011-01-18 13:29:42 +0100 |
---|---|---|
committer | Holger Hans Peter Freyther <zecke@selfish.org> | 2011-01-20 11:37:50 +0100 |
commit | bee2ed18c7fd1d8316a17a0ff3ba97f7b518c00e (patch) | |
tree | 2b10e515a533af24435e6b80ed17c6b0e27dd46d /src/mtp_layer3.c | |
parent | 84899a484c1a38bd487435160e1eaf9619c08b0d (diff) |
mtp: Make the input path work on a specific link of the linkset
Diffstat (limited to 'src/mtp_layer3.c')
-rw-r--r-- | src/mtp_layer3.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/mtp_layer3.c b/src/mtp_layer3.c index 0039747..1138d3c 100644 --- a/src/mtp_layer3.c +++ b/src/mtp_layer3.c @@ -466,7 +466,7 @@ static int mtp_link_sccp_data(struct mtp_link_set *link, struct mtp_level_3_hdr return 0; } -int mtp_link_set_data(struct mtp_link_set *link, struct msgb *msg) +int mtp_link_set_data(struct mtp_link *link, struct msgb *msg) { int rc = -1; struct mtp_level_3_hdr *hdr; @@ -475,7 +475,7 @@ int mtp_link_set_data(struct mtp_link_set *link, struct msgb *msg) if (!msg->l2h || msgb_l2len(msg) < sizeof(*hdr)) return -1; - if (!link->running) { + if (!link->the_link->running) { LOGP(DINP, LOGL_ERROR, "Link is not running. Call mtp_link_reset first: %p\n", link); return -1; } @@ -485,17 +485,17 @@ int mtp_link_set_data(struct mtp_link_set *link, struct msgb *msg) switch (hdr->ser_ind) { case MTP_SI_MNT_SNM_MSG: - rc = mtp_link_sign_msg(link, hdr, l3_len); + rc = mtp_link_sign_msg(link->the_link, hdr, l3_len); break; case MTP_SI_MNT_REG_MSG: - rc = mtp_link_regular_msg(link, hdr, l3_len); + rc = mtp_link_regular_msg(link->the_link, hdr, l3_len); break; case MTP_SI_MNT_SCCP: - rc = mtp_link_sccp_data(link, hdr, msg, l3_len); + rc = mtp_link_sccp_data(link->the_link, hdr, msg, l3_len); break; case MTP_SI_MNT_ISUP: msg->l3h = &hdr->data[0]; - rc = mtp_link_set_isup(link, msg, MTP_LINK_SLS(hdr->addr)); + rc = mtp_link_set_isup(link->the_link, msg, MTP_LINK_SLS(hdr->addr)); break; default: fprintf(stderr, "Unhandled: %u\n", hdr->ser_ind); |