Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: f84868ad4fae2f1fc88177503b7428575a513aec
Ticket: 686782ffffffffffffffffffffffffffffffffff
Changes to Tcl_SetObjLength() break "expect -re"
User & Date: rmax on 2003-02-18 04:34:23
Changes

  1. icomment:
    Logged In: YES 
    user_id=124643
    
    I think I gou it:
    expect.c around line 2220 modifies the contents of the
    pointer that comes back from Tcl_GetStringFromObj():
    
    ---- snip ----
    str = Tcl_GetStringFromObj(esPtr->buffer, &length);
    ...
    if (length != 0) {
        memmove(str,str+match,length-match);
    }
    Tcl_SetObjLength(esPtr->buffer, length-match);
    --- snap ----
    
    This modifies the string rep, but doesn't update the unicode
    string.
    
    
  2. login: "rmax"
  3. mimetype: "text/plain"
  4. title changed to: "Changes to Tcl_SetObjLength() break "expect -re""
  5. username: "rmax"