MFC r273904:
  Use in_localip() instead of handmade implementation.

Sponsored by:	Yandex LLC
MFC r274193:
  When mode isn't explicitly specified (wildcard) and inner protocol isn't
  IPv4 or IPv6, assume it is the transport mode.

Sponsored by:	Yandex LLC