Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 42d6fa4e16a91606273dcc1d649242ad2eed9586
Ticket: 879a0747bee593e2cd0f531fa723f5f5d5595527
Incomplete multibyte char @eof -> failed read
User & Date: ferrieux on 2015-04-20 18:12:07
Changes

  1. icomment:
    OK, the specificity of the file is very simple: it ends in mid-utf8-char ;)
    So you can reproduce with a mush smaller file:
    
     set ff [open foo w]
     fconfigure $ff -translation  binary
     puts -nonewline $ff "hello\xD7"
     close $ff
     set ff [open foo r] ;# here we inherit [encoding system]==utf-8
     set x [read $ff]
    
    So I guess that the multibyte machinery somehow gets into the way of the varied EOF flags. That should (and will) be cured, though the circumstances of the discovery are a bit contorted (you're basically reading a binary file with an utf-8 channel encoding).
    
  2. login: "ferrieux"
  3. mimetype: "text/plain"