+ if (authmask != HTTPD_AUTH_NONE)
+ printf("Web server is unauthenticated\n");
+ } else {
+ fprintf(stderr, PNAME ": authentication method not supported\n");
+ exit(1);
+ }
+ if (ntohs(addr.sin_addr.s_addr) == INADDR_ANY) {
+ printf("Server port: %d\n", ntohs(addr.sin_port));
+ } else if (ntohs(addr.sin_port) == 80) {
+ printf("URL: http://%s/\n", inet_ntoa(addr.sin_addr));
+ } else {
+ printf("URL: http://%s:%d/\n",
+ inet_ntoa(addr.sin_addr), ntohs(addr.sin_port));