static void set_port(struct sockaddr_storage *ss, int port)

{

    sockaddr_union ssu = (sockaddr_union){.storage = *ss};

    if (ss->ss_family == AF_INET)

        ssu.in.sin_port = htons(port);

#if HAVE_STRUCT_SOCKADDR_IN6

    else if (ss->ss_family == AF_INET6)

        ssu.in6.sin6_port = htons(port);

#endif

    *ss = ssu.storage;

}

static void set_port(struct sockaddr_storage *ss, int port)

{

    sockaddr_union ssu = (sockaddr_union){.storage = *ss};

    if (ss->ss_family == AF_INET)

        ssu.in.sin_port = htons(port);

#if HAVE_STRUCT_SOCKADDR_IN6

    else if (ss->ss_family == AF_INET6)

        ssu.in6.sin6_port = htons(port);

#endif

    *ss = ssu.storage;

}

static void FUNC_0(struct sockaddr_storage *VAR_0, int VAR_1)

{

    sockaddr_union ssu = (sockaddr_union){.storage = *VAR_0};

    if (VAR_0->ss_family == AF_INET)

        ssu.in.sin_port = htons(VAR_1);

#if HAVE_STRUCT_SOCKADDR_IN6

    else if (VAR_0->ss_family == AF_INET6)

        ssu.in6.sin6_port = htons(VAR_1);

#endif

    *VAR_0 = ssu.storage;

}

static void FUNC_0(struct sockaddr_storage *VAR_0, int VAR_1)
{ sockaddr_union ssu = (sockaddr_union){.storage = *VAR_0}; if (VAR_0->ss_family == AF_INET)
ssu.in.sin_port = htons(VAR_1); #if HAVE_STRUCT_SOCKADDR_IN6
else if (VAR_0->ss_family == AF_INET6)
ssu.in6.sin6_port = htons(VAR_1); #endif
*VAR_0 = ssu.storage; }