Skip to content
Tcl Source Code History Of Ticket 672938ffffffffff
Login

History Of Ticket 672938ffffffffff

Artifacts Associated With Ticket 672938ffffffffff

  1. Ticket change [cdb735fd18] (rid 95939) by nobody on 2003-01-23 06:53:35:

    1. assignee initialized to: "dkf"
    2. cmimetype initialized to: "text/plain"
    3. comment initialized to:
      At Tcl 8.3
      % exec echo [list 1 2 "3 and 4"]
      1 2 {3 and 4}
      
      This looks correct to me
      
      At Tcl 8.4
      % exec echo [list 1 2 "3 and 4"]
      1 2 \{3 and 4}
      
      Note the extra back-slash at 8.4 which looks wrong to 
      me.
      
      I am running on Windows (98) with version 
      ActiveTcl8.4.1.0-2-win32-ix86.exe
      
      [email protected]
      
      
      
    4. foundin initialized to: "obsolete: 8.4.1"
    5. priority initialized to: "5 Medium"
    6. resolution initialized to: "None"
    7. status initialized to: "Open"
    8. submitter initialized to: "nobody"
    9. subsystem initialized to: "16. Commands A-H"
    10. title initialized to: "Bad exec behaviour at Tcl 8.4.1"
    11. type initialized to: "Bug"
  2. Ticket change [c921894926] (rid 122229) by dkf on 2003-01-23 16:28:12:

    1. assignee changed to: "davygrvy"
    2. subsystem changed to: "27. Channel Types"
  3. Ticket change [5106a66620] (rid 126065) by softmick on 2003-01-24 00:26:28:

    1. icomment:
      Logged In: YES 
      user_id=695046
      
      I am advised that this problem (new at 8.4) could be a consequence of fixing a previous exec bug:
      
      554068
      
      
    2. login: "softmick"
    3. mimetype: "text/plain"
    4. username: "softmick"
  4. Ticket change [b87a1917af] (rid 128972) by dgp on 2003-01-24 04:40:59:

    1. icomment:
      Logged In: YES 
      user_id=80530
      
      Just curious whether this bug an Bug 554608
      were reported for the same release of Windows?
      
      
      
      
    2. login: "dgp"
    3. mimetype: "text/plain"
    4. username: "dgp"
  5. Ticket change [e91dfdc805] (rid 104757) by davygrvy on 2003-01-24 04:51:12:

    1. icomment:
      Logged In: YES 
      user_id=7549
      
      That behavior can be removed by taking out the part where 
      that is quoted.
      
      diff -c -r1.32 tclWinPipe.c
      *** tclWinPipe.c17 Dec 2002 02:47:39 -00001.32
      --- tclWinPipe.c23 Jan 2003 21:43:15 -0000
      ***************
      *** 1594,1604 ****
        Tcl_DStringAppend(&ds, "\\\"", 2);
        start = special + 1;
            }
      !     if (*special == '{') {
        Tcl_DStringAppend(&ds, start, special -
       start);
        Tcl_DStringAppend(&ds, "\\{", 2);
        start = special + 1;
      !     }
            if (*special == '\0') {
        break;
            }
      --- 1594,1604 ----
        Tcl_DStringAppend(&ds, "\\\"", 2);
        start = special + 1;
            }
      ! /*    if (*special == '{') {
        Tcl_DStringAppend(&ds, start, special -
       start);
        Tcl_DStringAppend(&ds, "\\{", 2);
        start = special + 1;
      !     }*/
            if (*special == '\0') {
        break;
            }
      
      What's interesting is that this is now showing itself.  There 
      are a set of rules this quoting mechanism needs to do so 
      args can be pulled back out of the single string and placed in 
      an argv array by the process that this line is handed.
      
      
    2. login: "davygrvy"
    3. mimetype: "text/plain"
    4. username: "davygrvy"
  6. Ticket change [067a80adb3] (rid 89234) by davygrvy on 2003-01-24 05:30:28:

    1. icomment:
      Logged In: YES 
      user_id=7549
      
      There is a double-quote problem in the current behavior of 
      BuildCommandLine().  Somehow this was recently broken.
      
      if the commandline is this to CreateProcess():
      a.exe b c=""d""
      
      _SHOULD_ expand to an argv array of
      argv[0] = a.exe
      argv[1] = b
      argv[2] = c="d"
      
      if the commandline is this to CreateProcess():
      a.exe b "c = d"
      
      _SHOULD_ expand to an argv array of
      argv[0] = a.exe
      argv[1] = b
      argv[2] = c = d
      
      GetCommandLine()->argv processing is done by the C-
      runtime of the process launched.  It is out of Tcl's control.  If 
      some processes follow the quoting rules and others do not...  
      then we're fighting a losing battle.
      
      
    2. login: "davygrvy"
    3. mimetype: "text/plain"
    4. username: "davygrvy"
  7. Ticket change [baddcd66df] (rid 129390) by davygrvy on 2003-01-24 05:33:58:

    1. icomment:
      Logged In: YES 
      user_id=7549
      
      % exec $env(COMSPEC) /c echo asd a="b"
      asd a=\"b\"
      
      The above should NOT be doing what you see.  
      BuildCommandLine() MUST turn those quotes into two and 
      NOT place a backslash in front of it.
      
      
    2. login: "davygrvy"
    3. mimetype: "text/plain"
    4. username: "davygrvy"
  8. Ticket change [8257b3a5a2] (rid 117223) by softmick on 2003-01-24 06:07:22:

    1. icomment:
      Logged In: YES 
      user_id=695046
      
      I do not quite understand the comments here, but I wonder 
      if it is helpful to add thaat if I call a second Tcl script from a 
      first script with arguments the problem is apparent. That 
      is, the second script will get aruments with extra back-
      slash characters in it:
      e.g. 
      exec wish printargs.tcl -- {3 and 4}
      So Tcl/Tk is not internally consistent. 
      I hope this helps. Mick
      
      
      
      
    2. login: "softmick"
    3. mimetype: "text/plain"
    4. username: "softmick"
  9. Ticket change [fd67fc4e06] (rid 108409) by davygrvy on 2003-01-24 06:12:38:

    1. icomment:
      Logged In: YES 
      user_id=7549
      
      Yes, Tcl must be internally consistent, but it must go 
      EXTERNAL to do it according to the quoting rules that the C-
      runtime uses.
      
      The rules for turning a commandline string into a vector is 
      contained by parse_cmdline() found in the MS runtime 
      src\crt\stdargv.c
      
      BuildCommandLine in tclWinPipe.c must be the inverse of 
      the runtime's parse_cmdline().  This is the problem here.
      
      
    2. login: "davygrvy"
    3. mimetype: "text/plain"
    4. username: "davygrvy"
  10. Ticket change [e69bd64e35] (rid 104319) by davygrvy on 2003-01-24 06:25:12:

    1. icomment:
      Logged In: YES 
      user_id=7549
      
      The problem is compounded by the fact that tclsh (in 
      win/tclAppInit.c) uses a custom argv setting routine that is 
      not the default of the runtime.
      
      We may fix Tcl to itself, but then calls to others apps will not 
      be correct which tends to show itself when launching cygwin 
      utilities which probably use a whole different rule set anyways.
      
      
    2. login: "davygrvy"
    3. mimetype: "text/plain"
    4. username: "davygrvy"
  11. Ticket change [c38d4aa983] (rid 111681) by davygrvy on 2003-01-24 06:29:55:

    1. icomment:
      Logged In: YES 
      user_id=7549
      
      Ok, first job is to make BuildCommandLine() exportable to 
      the private Stubs table so I can put it in a test suite.
      
      Then we can compare it against the runtime's parse_cmdline
      () and against the custom one of win/tclAppInit.c and get this 
      matter squashed.
      
      
    2. login: "davygrvy"
    3. mimetype: "text/plain"
    4. username: "davygrvy"
  12. Ticket change [fd43e78c3a] (rid 108385) by softmick on 2003-01-24 14:36:26:

    1. icomment:
      Logged In: YES 
      user_id=695046
      
      David
      
      The Tcl/Tk community is so very helpful. Thank you so much 
      for looking at my problem with such enthusiasm and skill! I 
      hopebody minds me putting this personal comment here for 
      the record.
      
      Mick
      
      
      
      
    2. login: "softmick"
    3. mimetype: "text/plain"
    4. username: "softmick"
  13. Ticket change [2723cd567a] (rid 88470) by vincentdarley on 2003-01-24 15:41:01:

    1. icomment:
      Logged In: YES 
      user_id=32170
      
      As dgp asked, the original problem was on Win2000. I don't know if 
      behaviour is different across different Win systems.  Also, as Dave 
      points out, cygwin may do something completely different -- if so, then 
      cygwin is at fault, I think -- we should fix for the standard Win shell.
      
      Anyway, I'm happy to test any proposed fixes, and we obviously need to 
      add appropriate tests to the test suite as well.
      
      
      
    2. login: "vincentdarley"
    3. mimetype: "text/plain"
    4. username: "vincentdarley"
  14. Ticket change [dc1d3a909f] (rid 108077) by softmick on 2003-01-24 22:34:21:

    1. icomment:
      Logged In: YES 
      user_id=695046
      
      When I found the problem, I was sending arguments from one Tcl/Tk script to another. In trying to understand the 
      problem, I simplified it to running echo (from cygwin) from the wish shell by hand. It looks to me like cygwin reads 
      the arguments exactly the same way the Tcl/Tk does now. I am assuming that the problem is with sending the 
      arguments rather than reading them - hence your error going via $env(COMSPEC). Therefore, I am hopeful that 
      cygwin interfaces will prove OK.
      
      I am unable to compile, but other than that, I am happy to help test.
      
      [email protected] 
      
      
      
      
    2. login: "softmick"
    3. mimetype: "text/plain"
    4. username: "softmick"
  15. Ticket change [a7a5a84d3d] (rid 98843) by hobbs on 2003-05-11 07:15:09:

    1. priority changed to: "7 High"
  16. Ticket change [16bbbc53ac] (rid 124759) by davygrvy on 2003-12-16 17:06:56:

    1. icomment:
      
      
      File Added - 70719: patch.txt
      
      Logged In: YES 
      user_id=7549
      
      Here's a patch that fixes this.  It needs some more work to 
      polish it.
      
      
    2. login: "davygrvy"
    3. mimetype: "text/plain"
    4. username: "davygrvy"
  17. Ticket change [fbf8762912] (rid 108151) by davygrvy on 2004-01-29 04:28:41:

    1. icomment:
      
      
      File Added - 75040: patch.txt
      
      Logged In: YES 
      user_id=7549
      
      Updated patch..  Needs test suite additions or, rather, 
      verification with cases.
      
      
    2. login: "davygrvy"
    3. mimetype: "text/plain"
    4. username: "davygrvy"
  18. Add attachment "patch.txt" [2185f73161] (rid 130600) by davygrvy on 2004-01-29 04:28:41.

  19. Ticket change [8e0c914d79] (rid 120052) by davygrvy on 2004-01-29 04:28:42:

    1. icomment:
      
      
      File Deleted - 70719: 
      
      
      
    2. login: "davygrvy"
    3. mimetype: "text/plain"
    4. username: "davygrvy"
  20. Ticket change [2104f7d927] (rid 130512) by davygrvy on 2004-02-01 16:29:12:

    1. closedate changed to: "2004-02-01T09:29:12"
    2. closer changed to: "davygrvy"
    3. icomment:
      Logged In: YES 
      user_id=7549
      
      Committing fix to HEAD. tclWinPipe.c -r1.41
      
      
    4. login: "davygrvy"
    5. mimetype: "text/plain"
    6. resolution changed to: "Fixed"
    7. status changed to: "Closed"
    8. username: "davygrvy"
  21. Ticket change [7a96073f49] (rid 90353) by davygrvy on 2004-02-01 18:27:00:

    1. icomment:
      Logged In: YES 
      user_id=7549
      
      FYI, no test case existed to show the need for the custom 
      setargv() used in both the tcl and wish shells.  Therefore, it 
      was removed in favor of the c-runtime's work.
      
      
    2. login: "davygrvy"
    3. mimetype: "text/plain"
    4. username: "davygrvy"
  22. Ticket change [1dd6cf35fe] (rid 90881) by dgp on 2004-02-03 01:11:27:

    1. icomment:
      Logged In: YES 
      user_id=80530
      
      
      What does this change
      do to Tcl Bug 554068?
      
      
    2. login: "dgp"
    3. mimetype: "text/plain"
    4. username: "dgp"