PRNetAddr any_address, client_address;  rv = PR_InitializeNetAddr(PR_IpAddrAny, default_port, &any_address); PR_ASSERT(PR_SUCCESS == rv);  rv = PR_Bind(stack, &any_address); PR_ASSERT(PR_SUCCESS == rv); rv = PR_Listen(stack, 10); PR_ASSERT(PR_SUCCESS == rv);
PRNetAddr client_address;
static void PR_CALLBACK Server(void *arg){    PRStatus rv;    PRUint8 buffer[100];    PRFileDesc *service;    PRUintn empty_flags = 0;    PRIntn bytes_read, bytes_sent;    PRFileDesc *stack = (PRFileDesc*)arg;    PRNetAddr any_address, client_address;    rv = PR_InitializeNetAddr(PR_IpAddrAny, default_port, &any_address);    PR_ASSERT(PR_SUCCESS == rv);    rv = PR_Bind(stack, &any_address); PR_ASSERT(PR_SUCCESS == rv);    rv = PR_Listen(stack, 10); PR_ASSERT(PR_SUCCESS == rv);    service = PR_Accept(stack, &client_address, PR_INTERVAL_NO_TIMEOUT);    if (verbosity > quiet)        PR_fprintf(logFile, "Server accepting connection\n");    do    {        bytes_read = PR_Recv(            service, buffer, sizeof(buffer), empty_flags, PR_INTERVAL_NO_TIMEOUT);        if (0 != bytes_read)        {            if (verbosity > chatty)                PR_fprintf(logFile, "Server receiving %d bytes\n", bytes_read);            PR_ASSERT(bytes_read > 0);            bytes_sent = PR_Send(                service, buffer, bytes_read, empty_flags, PR_INTERVAL_NO_TIMEOUT);            if (verbosity > chatty)                PR_fprintf(logFile, "Server sending %d bytes\n", bytes_sent);            PR_ASSERT(bytes_read == bytes_sent);        }    } while (0 != bytes_read);    if (verbosity > quiet)        PR_fprintf(logFile, "Server shutting down and closing stack\n");    rv = PR_Shutdown(service, PR_SHUTDOWN_BOTH); PR_ASSERT(PR_SUCCESS == rv);    rv = PR_Close(service); PR_ASSERT(PR_SUCCESS == rv);}  /* Server */