--- gvpe/src/vpn_tcp.C 2003/04/07 01:28:56 1.5 +++ gvpe/src/vpn_tcp.C 2003/10/14 03:22:09 1.7 @@ -171,9 +171,10 @@ u16 plen = htons (w_pkt->len); iovec vec[2]; - vec[0].iov_base = ((u8 *)&plen) + w_ofs; + //TODO: char* is the right type? hardly... + vec[0].iov_base = (char *)((u8 *)&plen) + w_ofs; vec[0].iov_len = 2 - w_ofs; - vec[1].iov_base = &((*w_pkt)[0]); + vec[1].iov_base = (char *)&((*w_pkt)[0]); vec[1].iov_len = w_len - 2; len = writev (fd, vec, 2); @@ -322,7 +323,7 @@ if (i < 12) { - slog (L_ERR, _("%s: unable to do proxy-forwarding, short response"), + slog (L_ERR, _("(%s): unable to do proxy-forwarding, short response"), (const char *)si); error (); } @@ -330,7 +331,7 @@ || r[5] != '1' // http-major || r[9] != '2') // response { - slog (L_ERR, _("%s: malformed or unexpected proxy response (%.12s)"), + slog (L_ERR, _("(%s): malformed or unexpected proxy response (%.12s)"), (const char *)si, r); error (); } @@ -403,7 +404,9 @@ { // how this maps to the underlying tcp packets we don't know // and we don't care. at least we tried ;) +#if defined(SOL_IP) && defined(IP_TOS) setsockopt (fd, SOL_IP, IP_TOS, &tos, sizeof tos); +#endif w_pkt = pkt; w_ofs = 0;