if (!local)
{
/* route remote host to original default gateway */
- if (rl->spec.remote_host != 0xffffffff) {
+ if (rl->spec.remote_host != IPV4_INVALID_ADDR) {
add_route3 (rl->spec.remote_host,
~0,
rl->spec.net_gateway,
*/
#ifdef USE_PF_INET6
if (lsa->actual.dest.addr.sa.sa_family != AF_INET)
- return 0xffffffff;
+ return IPV4_INVALID_ADDR;
#else
ASSERT (lsa->actual.dest.addr.sa.sa_family == AF_INET);
#endif
void bad_address_length (int actual, int expected);
+#ifdef USE_PF_INET6
+/* IPV4_INVALID_ADDR: returned by link_socket_current_remote()
+ * to ease redirect-gateway logic for ipv4 tunnels on ipv6 endpoints
+ */
+#define IPV4_INVALID_ADDR 0xffffffff
+#endif
in_addr_t link_socket_current_remote (const struct link_socket_info *info);
void link_socket_connection_initiated (const struct buffer *buf,