From: Ryan Bloom Date: Mon, 22 Nov 1999 14:52:17 +0000 (+0000) Subject: Clean up the getopt stuff a bit. Basically, I am removing the #define's, X-Git-Tag: 1.3.10~156 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=444531b69183851a43ac38dddb6528390b951cb5;p=apache Clean up the getopt stuff a bit. Basically, I am removing the #define's, and changing the names in the getopt.c file so that we are sure there is no namespace collision between regular getopt's, and APR's getopt. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@84143 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/server/main.c b/server/main.c index 70ba9161c5..99ed728903 100644 --- a/server/main.c +++ b/server/main.c @@ -265,8 +265,6 @@ static void usage(process_rec *process) ap_context_t *g_pHookPool; -API_VAR_IMPORT char *optarg; - #ifdef WIN32 API_EXPORT_NONSTD(int) apache_main(int argc, char *argv[]) #else @@ -303,17 +301,17 @@ API_EXPORT_NONSTD(int) main(int argc, char *argv[]) switch (c) { case 'c': new = (char **)ap_push_array(ap_server_post_read_config); - *new = ap_pstrdup(pcommands, optarg); + *new = ap_pstrdup(pcommands, ap_optarg); break; case 'C': new = (char **)ap_push_array(ap_server_pre_read_config); - *new = ap_pstrdup(pcommands, optarg); + *new = ap_pstrdup(pcommands, ap_optarg); break; case 'd': - def_server_root = optarg; + def_server_root = ap_optarg; break; case 'f': - confname = optarg; + confname = ap_optarg; break; case 'v': printf("Server version: %s\n", ap_get_server_version());