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

History Of Ticket 461322ffffffffff

Artifacts Associated With Ticket 461322ffffffffff

  1. Ticket change [e98934a90a] (rid 104831) by chris_nelson on 2001-09-13 20:15:20:

    1. assignee initialized to: "nobody"
    2. cmimetype initialized to: "text/plain"
    3. comment initialized to:
      On at least Solaris 2.8, a fairly simple, stupid use of [regsub] produces corrupt output.  It may be 
      that it uses some weird encoding.
      
      It seems to be necessary that the expression and the substitute string are the same.  It seems 
      very sensitive to order of operations that preceed it.  I'm fairly confident it has to do with object 
      representation.
      
      The following script:
      
        set pti(a) abcdefghijklmnopqurstuvwxyz
        set b      $pti(a)
        set pti(c) abcdefghijklmnopqurstuvwxyz0123456789
      
        puts "replace \n\t$pti(a)\nwith\n\t$b\nin\n\t$pti(c)"
        puts "string length:[string length $pti(c)]"
        puts "string byte length:[string bytelength $pti(c)]"
      
        regsub $pti(a) $pti(c) $b d
      
        puts "result:\n\t$d"
        puts "string length:[string length $d]"
        puts "string byte length:[string bytelength $d]"
      
      Produces the following erroneous output:
      
        replace 
              abcdefghijklmnopqurstuvwxyz
        with
              abcdefghijklmnopqurstuvwxyz
        in
              abcdefghijklmnopqurstuvwxyz0123456789
        string length:37
        string byte length:37
        result:
              ab?efijklmnopqurstuvwxyz0123456789
        string length:37
        string byte length:41
      
      At times during my quest to build a nice test case, I got 3-5 ?'s at the start of the string and 
      bytelengths up to 45.
      
      NOTE: If 
      
        set pti(a) abcdefghijklmnopqurstuvwxyz
        set b      $pti(a)
      
      is replaced by:
      
        set pti(a) abcdefghijklmnopqurstuvwxyz
        set b       abcdefghijklmnopqurstuvwxyz
      
      the problem does not seem to occur!
      
      
    4. foundin initialized to: "obsolete: 8.4a3"
    5. priority initialized to: "5 Medium"
    6. resolution initialized to: "None"
    7. status initialized to: "Open"
    8. submitter initialized to: "chris_nelson"
    9. subsystem initialized to: "43. Regexp"
    10. title initialized to: "regsub trashes encoding?"
    11. type initialized to: "Bug"
  2. Ticket change [442aa2e767] (rid 116678) by msofer on 2001-09-14 03:24:19:

    1. icomment:
      Logged In: YES 
      user_id=148712
      
      Problem confirmed in linux with tcl8.4a3 and tcl8.4a4; does
      not seem to happen on tcl8.3.3
      
      
      
    2. login: "msofer"
    3. mimetype: "text/plain"
    4. username: "msofer"
  3. Ticket change [aa92d9c3c3] (rid 100947) by andreas_kupries on 2001-09-14 03:25:11:

    1. assignee changed to: "hobbs"
    2. icomment:
      Logged In: YES 
      user_id=75003
      
      I remember that Jeff fixed recently a bug in this area.
      Assigning this to him. Priority up as eye-catcher.
      
      
      
    3. login: "andreas_kupries"
    4. mimetype: "text/plain"
    5. priority changed to: "7 High"
    6. username: "andreas_kupries"
  4. Add attachment "461322.patch" [96f8d135fd] (rid 106428) by hobbs on 2001-09-14 06:46:45.

  5. Ticket change [8e9c35e92c] (rid 120141) by hobbs on 2001-09-14 06:46:45:

    1. closedate changed to: "2001-09-13T23:46:45"
    2. closer changed to: "hobbs"
    3. icomment:
      
      
      File Added - 10758: 461322.patch
      
      Logged In: YES 
      user_id=72656
      
      This is an insidious problem related to shimmering where 
      some commands that get passed the same object will need to 
      duplicate the object to ensure correctness.  This may occur 
      in other areas, but the patch for regsub is attached.  
      Fixed in 8.4a4cvs.
      
      
    4. login: "hobbs"
    5. mimetype: "text/plain"
    6. resolution changed to: "Fixed"
    7. status changed to: "Closed"
    8. username: "hobbs"