diff options
author | Christian Grothoff <christian@grothoff.org> | 2012-01-15 19:00:22 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2012-01-15 19:00:22 +0000 |
commit | 5ec7048ed9ffeddbe06e34a31d388080fae143e5 (patch) | |
tree | e8f5d99371337968edc0ee2cb42f00ed58eae52d /src | |
parent | f60003d0485d2e0c1b1b4013801abb3ab080e811 (diff) | |
download | gnunet-5ec7048ed9ffeddbe06e34a31d388080fae143e5.tar.gz gnunet-5ec7048ed9ffeddbe06e34a31d388080fae143e5.zip |
-initialize msg field in tnq
Diffstat (limited to 'src')
-rw-r--r-- | src/vpn/gnunet-service-vpn.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/vpn/gnunet-service-vpn.c b/src/vpn/gnunet-service-vpn.c index c9d5bb110..afa577f98 100644 --- a/src/vpn/gnunet-service-vpn.c +++ b/src/vpn/gnunet-service-vpn.c | |||
@@ -898,6 +898,7 @@ route_packet (struct DestinationEntry *destination, | |||
898 | } | 898 | } |
899 | tnq = GNUNET_malloc (sizeof (struct TunnelMessageQueueEntry) + mlen); | 899 | tnq = GNUNET_malloc (sizeof (struct TunnelMessageQueueEntry) + mlen); |
900 | tnq->len = mlen; | 900 | tnq->len = mlen; |
901 | tnq->msg = &tnq[1]; | ||
901 | usm = (struct GNUNET_EXIT_UdpServiceMessage *) &tnq[1]; | 902 | usm = (struct GNUNET_EXIT_UdpServiceMessage *) &tnq[1]; |
902 | usm->header.size = htons ((uint16_t) mlen); | 903 | usm->header.size = htons ((uint16_t) mlen); |
903 | usm->header.type = htons (GNUNET_MESSAGE_TYPE_VPN_UDP_TO_SERVICE); | 904 | usm->header.type = htons (GNUNET_MESSAGE_TYPE_VPN_UDP_TO_SERVICE); |
@@ -927,6 +928,7 @@ route_packet (struct DestinationEntry *destination, | |||
927 | tnq = GNUNET_malloc (sizeof (struct TunnelMessageQueueEntry) + | 928 | tnq = GNUNET_malloc (sizeof (struct TunnelMessageQueueEntry) + |
928 | mlen); | 929 | mlen); |
929 | tnq->len = mlen; | 930 | tnq->len = mlen; |
931 | tnq->msg = &tnq[1]; | ||
930 | uim = (struct GNUNET_EXIT_UdpInternetMessage *) &tnq[1]; | 932 | uim = (struct GNUNET_EXIT_UdpInternetMessage *) &tnq[1]; |
931 | uim->header.size = htons ((uint16_t) mlen); | 933 | uim->header.size = htons ((uint16_t) mlen); |
932 | uim->header.type = htons (GNUNET_MESSAGE_TYPE_VPN_UDP_TO_INTERNET); | 934 | uim->header.type = htons (GNUNET_MESSAGE_TYPE_VPN_UDP_TO_INTERNET); |
@@ -969,6 +971,7 @@ route_packet (struct DestinationEntry *destination, | |||
969 | } | 971 | } |
970 | tnq = GNUNET_malloc (sizeof (struct TunnelMessageQueueEntry) + mlen); | 972 | tnq = GNUNET_malloc (sizeof (struct TunnelMessageQueueEntry) + mlen); |
971 | tnq->len = mlen; | 973 | tnq->len = mlen; |
974 | tnq->msg = &tnq[1]; | ||
972 | tsm = (struct GNUNET_EXIT_TcpServiceStartMessage *) &tnq[1]; | 975 | tsm = (struct GNUNET_EXIT_TcpServiceStartMessage *) &tnq[1]; |
973 | tsm->header.size = htons ((uint16_t) mlen); | 976 | tsm->header.size = htons ((uint16_t) mlen); |
974 | tsm->header.type = htons (GNUNET_MESSAGE_TYPE_VPN_TCP_TO_SERVICE_START); | 977 | tsm->header.type = htons (GNUNET_MESSAGE_TYPE_VPN_TCP_TO_SERVICE_START); |
@@ -995,6 +998,7 @@ route_packet (struct DestinationEntry *destination, | |||
995 | } | 998 | } |
996 | tnq = GNUNET_malloc (sizeof (struct TunnelMessageQueueEntry) + mlen); | 999 | tnq = GNUNET_malloc (sizeof (struct TunnelMessageQueueEntry) + mlen); |
997 | tnq->len = mlen; | 1000 | tnq->len = mlen; |
1001 | tnq->msg = &tnq[1]; | ||
998 | tim = (struct GNUNET_EXIT_TcpInternetStartMessage *) &tnq[1]; | 1002 | tim = (struct GNUNET_EXIT_TcpInternetStartMessage *) &tnq[1]; |
999 | tim->header.size = htons ((uint16_t) mlen); | 1003 | tim->header.size = htons ((uint16_t) mlen); |
1000 | tim->header.type = htons (GNUNET_MESSAGE_TYPE_VPN_TCP_TO_INTERNET_START); | 1004 | tim->header.type = htons (GNUNET_MESSAGE_TYPE_VPN_TCP_TO_INTERNET_START); |
@@ -1033,6 +1037,7 @@ route_packet (struct DestinationEntry *destination, | |||
1033 | } | 1037 | } |
1034 | tnq = GNUNET_malloc (sizeof (struct TunnelMessageQueueEntry) + mlen); | 1038 | tnq = GNUNET_malloc (sizeof (struct TunnelMessageQueueEntry) + mlen); |
1035 | tnq->len = mlen; | 1039 | tnq->len = mlen; |
1040 | tnq->msg = &tnq[1]; | ||
1036 | tdm = (struct GNUNET_EXIT_TcpDataMessage *) &tnq[1]; | 1041 | tdm = (struct GNUNET_EXIT_TcpDataMessage *) &tnq[1]; |
1037 | tdm->header.size = htons ((uint16_t) mlen); | 1042 | tdm->header.size = htons ((uint16_t) mlen); |
1038 | tdm->header.type = htons (GNUNET_MESSAGE_TYPE_VPN_TCP_DATA); | 1043 | tdm->header.type = htons (GNUNET_MESSAGE_TYPE_VPN_TCP_DATA); |