Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: d2565f8c7ff1a93d6d624d27c33624a9b2409c9b53958db7ef20719d8525014f
Ticket: 133456085a95005372096bc16277d54e8cb39b6a
Tcl 9: Reading UTF-8 data which contains "noncharacter" code points
User & Date: pointsman on 2022-11-28 20:42:29
Changes

  1. assignee changed to: "nobody"
  2. closer changed to: "nobody"
  3. cmimetype changed to: "text/plain"
  4. comment changed to:
    To create the test data simplest is to use a 8.6 tclsh
    
    % info patchlevel
    8.6.12
    % encoding system
    utf-8
    % set fd [open test.data w+]
    file3
    % puts $fd \uffff\uffff\uffffabc
    % close $fd
    
    The created file contains the byte sequence
    
    ef bf bf ef bf bf ef bf bf 61 62 63 0a
    
    as expected.
    
    Now try to read this file with Tcl 9:
    
    % info patchlevel
    9.0a4
    % encoding system
    utf-8
    % set fd [open test.data]
    file6
    % set data [read $fd]
    % string length $data
    0
    
    Ahem, ... what?
    
  5. foundin changed to: "9.0"
  6. is_private changed to: "0"
  7. login: "pointsman"
  8. priority changed to: "5 Medium"
  9. private_contact changed to: "4ca203a8e925aecdd9419645f936bccf18cd6ea7"
  10. resolution changed to: "None"
  11. severity changed to: "Critical"
  12. status changed to: "Open"
  13. submitter changed to: "pointsman"
  14. subsystem changed to: "25. Channel System"
  15. title changed to:
     Tcl 9: Reading UTF-8 data which contains "noncharacter" code points
    
  16. type changed to: "Bug"