rem: Arguments[i]= argv[i];
add: { Arguments[i]= argv[i]; }
context: real_main(int argc, char **argv){    int i, restart=0;    char *str, *alt;    int d, s;#ifdef DEBUG    Bool doSync = False;#endif    setlocale(LC_ALL, "");    wsetabort(wAbort);    /* for telling WPrefs what's the name of the wmaker binary being ran */    str = wstrconcat("WMAKER_BIN_NAME=", argv[0]);    putenv(str);    ArgCount = argc+1;    Arguments = wmalloc(sizeof(char*)*(ArgCount+2));    for (i= 0; i < argc; i++)      Arguments[i]= argv[i];    /* add the extra option to signal that we're just restarting wmaker */    Arguments[argc]= "--for-real=";    Arguments[argc+1]= NULL;    WMInitializeApplication("WindowMaker", &argc, argv);    ProgName = strrchr(argv[0],'/');    if (!ProgName)        ProgName = argv[0];    else        ProgName++;    restart = 0;    memset(&wPreferences, 0, sizeof(WPreferences));    wPreferences.fallbackWMs = WMCreateArray(8);    alt = getenv("WINDOWMAKER_ALT_WM");    if (alt != NULL)        WMAddToArray(wPreferences.fallbackWMs, wstrdup(alt));    WMAddToArray(wPreferences.fallbackWMs, wstrdup(FALLBACK_WINDOWMANAGER));    WMAddToArray(wPreferences.fallbackWMs, wstrdup("metacity"));    WMAddToArray(wPreferences.fallbackWMs, wstrdup("fvwm"));    WMAddToArray(wPreferences.fallbackWMs, wstrdup("twm"));    WMAddToArray(wPreferences.fallbackWMs, NULL);    WMAddToArray(wPreferences.fallbackWMs, wstrdup("rxvt"));    WMAddToArray(wPreferences.fallbackWMs, wstrdup("xterm"));    if (argc>1) {        for (i=1; i<argc; i++) {#ifdef USECPP            if (strcmp(argv[i], "-nocpp")==0                || strcmp(argv[i], "--no-cpp")==0) {                wPreferences.flags.nocpp=1;            } else#endif                if (strcmp(argv[i], "--for-real")==0) {                    wPreferences.flags.restarting = 0;                } else if (strcmp(argv[i], "--for-real=")==0) {                    wPreferences.flags.restarting = 1;                } else if (strcmp(argv[i], "--for-real-")==0) {                    wPreferences.flags.restarting = 2;                } else if (strcmp(argv[i], "-no-autolaunch")==0                    || strcmp(argv[i], "--no-autolaunch")==0) {                    wPreferences.flags.noautolaunch = 1;                } else if (strcmp(argv[i], "-dont-restore")==0                           || strcmp(argv[i], "--dont-restore")==0) {                    wPreferences.flags.norestore = 1;                } else if (strcmp(argv[i], "-nodock")==0                           || strcmp(argv[i], "--no-dock")==0) {                    wPreferences.flags.nodock=1;                } else if (strcmp(argv[i], "-noclip")==0                           || strcmp(argv[i], "--no-clip")==0) {                    wPreferences.flags.noclip=1;                } else if (strcmp(argv[i], "-version")==0                           || strcmp(argv[i], "--version")==0) {                    printf("Window Maker %s\n", VERSION);                    exit(0);                } else if (strcmp(argv[i], "--global_defaults_path")==0) {                    printf("%s/WindowMaker\n", SYSCONFDIR);                    exit(0);#ifdef DEBUG                } else if (strcmp(argv[i], "--synchronous")==0) {                    doSync = 1;#endif                } else if (strcmp(argv[i], "-locale")==0                           || strcmp(argv[i], "--locale")==0) {                    i++;                    if (i>=argc) {                        wwarning(_("too few arguments for %s"), argv[i-1]);                        exit(0);                    }                    Locale = argv[i];                } else if (strcmp(argv[i], "-display")==0                           || strcmp(argv[i], "--display")==0) {                    i++;                    if (i>=argc) {                        wwarning(_("too few arguments for %s"), argv[i-1]);                        exit(0);                    }                    DisplayName = argv[i];                } else if (strcmp(argv[i], "-visualid")==0                           || strcmp(argv[i], "--visual-id")==0) {                    i++;                    if (i>=argc) {                        wwarning(_("too few arguments for %s"), argv[i-1]);                        exit(0);                    }                    if (sscanf(argv[i], "%i", &wVisualID)!=1) {                        wwarning(_("bad value for visualid: \"%s\""), argv[i]);                        exit(0);                    }                } else if (strcmp(argv[i], "-static")==0                           || strcmp(argv[i], "--static")==0) {                    wPreferences.flags.noupdates = 1;                } else if (strcmp(argv[i], "-nopolling")==0                           || strcmp(argv[i], "--no-polling")==0) {                    wPreferences.flags.nopolling = 1;#ifdef XSMP_ENABLED                } else if (strcmp(argv[i], "-clientid")==0                           || strcmp(argv[i], "-restore")==0) {                    i++;                    if (i>=argc) {                        wwarning(_("too few arguments for %s"), argv[i-1]);                        exit(0);                    }#endif                } else if (strcmp(argv[i], "--help")==0) {                    print_help();                    exit(0);                } else {                    printf(_("%s: invalid argument '%s'\n"), argv[0], argv[i]);                    printf(_("Try '%s --help' for more information\n"), argv[0]);                    exit(1);                }        }    }    if (!wPreferences.flags.noupdates) {        /* check existence of Defaults DB directory */        check_defaults();    }    if (Locale) {        /* return of wstrconcat should not be free-ed! read putenv man page */        putenv(wstrconcat("LANG=", Locale));    } else {        Locale = getenv("LC_ALL");        if (!Locale) {            Locale = getenv("LANG");        }    }    setlocale(LC_ALL, "");    if (!Locale || strcmp(Locale, "C")==0 || strcmp(Locale, "POSIX")==0)        Locale = NULL;#ifdef I18N    if (getenv("NLSPATH"))        bindtextdomain("WindowMaker", getenv("NLSPATH"));    else        bindtextdomain("WindowMaker", LOCALEDIR);    textdomain("WindowMaker");    if (!XSupportsLocale()) {        wwarning(_("X server does not support locale"));    }    if (XSetLocaleModifiers("") == NULL) {        wwarning(_("cannot set locale modifiers"));    }#endif    if (Locale) {        char *ptr;        Locale = wstrdup(Locale);        ptr = strchr(Locale, '.');        if (ptr)            *ptr = 0;    }    /* open display */    dpy = XOpenDisplay(DisplayName);    if (dpy == NULL) {        wfatal(_("could not open display \"%s\""), XDisplayName(DisplayName));        exit(1);    }    if (fcntl(ConnectionNumber(dpy), F_SETFD, FD_CLOEXEC) < 0) {        wsyserror("error setting close-on-exec flag for X connection");        exit(1);    }    /* check if the user specified a complete display name (with screen).     * If so, only manage the specified screen */    if (DisplayName)        str = strchr(DisplayName, ':');    else        str = NULL;    if (str && sscanf(str, ":%i.%i", &d, &s)==2)        multiHead = False;    DisplayName = XDisplayName(DisplayName);    {        int len = strlen(DisplayName)+64;        str = wmalloc(len);        snprintf(str, len, "DISPLAY=%s", DisplayName);    }    putenv(str);#ifdef DEBUG    if (doSync)        XSynchronize(dpy, True);#endif    wXModifierInitialize();#ifdef XSMP_ENABLED    wSessionConnectManager(argv, argc);#endif    StartUp(!multiHead);    if (wScreenCount==1)        multiHead = False;    execInitScript();    EventLoop();    return -1;}