win98, ctrl-c & System.system (was: Updated 6.4 Windows installer RC)

Claus Reinke claus.reinke at talk21.com
Wed Mar 23 12:05:36 EST 2005


> There's no such thing as cmd.exe on Win9x, it's COMMAND.EXE/COM.

on my win98se system, there's no COMMAND.EXE, either, only
COMMAND.COM.

> Some System.Process.* code ought to be looking at the COMSPEC env
> variable and not hard-code the name of the command processor. .... why the
> switch away from just using libc/msvcrt's system() for System.system?

agreed, on both counts. sounds like a case of "never change a winning
team", not. but I guess when one introduces a new framework for rawSystem,
one wants to keep only one way of doing things instead of two?

>However, I don't think COMMAND.EXE supports the /c switch...

don't know about that one, but COMMAND.COM does support it:

$ echo $COMSPEC
C:\WINDOWS\COMMAND.COM

$ /c/Windows/COMMAND.COM /c cd
C:\Windows\Desktop\haskell\monadification

in principle, this would make it possible to implement system on top of
rawSystem, but as I said, I can't see a way of passing the /c switch
through rawSystem without triggering error messages.

cheers,
claus


--------------------
$ /c/Windows/COMMAND.COM


Microsoft(R) Windows 98
   (C)Copyright Microsoft Corp 1981-1999.

C:\Windows\Desktop\haskell\monadification>command /?
Startet eine weitere Kopie des Windows-Befehlsinterpreters.

COMMAND [[Laufwerk:]Pfad] [Gerät] [/E:nnnnn] [/L:nnnn] [/U:nnn] [/P] [/MSG]
                       [/LOW] [/Y [/[C|K] Befehl]]
  [Laufwerk:]Pfad   Das Verzeichnis, das die Datei COMMAND.COM enthält.
  Gerät             Das Gerät für die Befehlsein- und -ausgabe.
  /E:nnnnn          Legt die Umgebungsgröße auf nnnnn Bytes fest.
                    (nnnnn sollte im Bereich von 256 bis 32,768 liegen).
  /L:nnnn           Definiert die Länge des internen Puffers
                    (/P ebenfalls erforderlich).
                    (nnnn sollte im Bereich von 128 bis 1.024 liegen).
  /U:nnn            Definiert die Länge des Eingabepuffers
                    (/P ebenfalls erforderlich).
                    (nnn sollte im Bereich von 128 bis 255 liegen).
  /P                Installiert den neuen Befehlsinterpreter dauerhaft
                    (ohne Möglichkeit zum Beenden).
  /MSG              Speichert alle Fehlermeldungen im Arbeitsspeicher
                    (/P ebenfalls erforderlich).
  /LOW              Residente Daten werden im unteren Speicherbereich
                    untergebracht.
  /Y                Führt das mit /C oder /K angegebene
                    Stapelverarbeitungsprogramm schrittweise aus.
  /C Befehl         Der Befehl wird ausgeführt und COMMAND.COM beendet.
  /K Befehl         Der Befehl wird ausgeführt und COMMAND.COM nicht beendet.






More information about the Glasgow-haskell-bugs mailing list