Skip to content
Tcl Source Code History Of Ticket d433c0e0ad
Login

History Of Ticket d433c0e0ad

Artifacts Associated With Ticket d433c0e0ad

  1. Ticket change [2fb00348c4] (rid 176937) by chw on 2019-11-12 23:43:27:

    1. assignee initialized to: "nobody"
    2. closer initialized to: "nobody"
    3. cmimetype initialized to: "text/plain"
    4. comment initialized to:
      On Debian 9 using
      
       $ cd .../unix ; CC="cc -DTCL_UTF_MAX=4" ./configure --prefix=/tmp/mytcl --disable-static ; make
       $ ./tclsh
       % set X "\U1F602"
      
      freezes when run in a gnome-terminal.
      
      If an xterm is used instead, more chars than expected are output from the tclsh, as shown in
      this strace dump:
      
       write(1, "\360\302\230\302\230\302\202\r\n", 9) = 9
      
      When rebuilding with
      
       $ cd .../unix ; CC="cc -DTCL_UTF_MAX=6" ./configure --prefix=/tmp/mytcl --disable-static ; make
       $ ./tclsh
       % set X "\U1F602"
      
      the emoji is properly displayed in gnome-terminal and strace yields the expected
      
       write(1, "\360\237\230\202\r\n",  6) = 6
      
      Right now, this ticket is a showstopper for undroidwish/vanillawish (not for AndroidWish).
      
    5. foundin initialized to: "core-8-6-10-rc"
    6. is_private initialized to: "0"
    7. login: "chw"
    8. priority initialized to: "5 Medium"
    9. private_contact initialized to: "0b3aff16612e1e9f3b675963fa64e01bd1d89307"
    10. resolution initialized to: "None"
    11. severity initialized to: "Cosmetic"
    12. status initialized to: "Open"
    13. submitter initialized to: "chw"
    14. subsystem initialized to: "44. UTF-8 Strings"
    15. title initialized to: "TCL_UTF_MAX == 4 problems"
    16. type initialized to: "Bug"
  2. Ticket change [ce383bd55f] (rid 176938) by chw on 2019-11-13 06:42:25:

    1. icomment:
      The core-8-7-a3-rc branch built with
      
       $ cd .../unix ; CC="cc -DTCL_UTF_MAX=4" ./configure --prefix=/tmp/mytcl --disable-static ; make
       $ ./tclsh
       % set X "\U1F602"
      
      gives some weird output in gnome-terminal and the strace dump is:
      
       write(1, "\360\313\234\313\234\342\200\232\r\n", 10)
      
    2. login: "chw"
    3. mimetype: "text/plain"
  3. Ticket change [c9124ea821] (rid 176939) by chw on 2019-11-13 06:47:37:

    1. icomment:
      For reference, the core-8-6-9 branch built with
      
       $ cd .../unix ; CC="cc -DTCL_UTF_MAX=4" ./configure --prefix=/tmp/mytcl --disable-static ; make
       $ ./tclsh
       % set X "\U1F602"
      
      outputs the expected emoji and the strace dump is:
      
       write(1, "\360\237\230\202\r\n", 6) = 6
      
    2. login: "chw"
    3. mimetype: "text/plain"
  4. Ticket change [4eb5c62f06] (rid 176940) by jan.nijtmans on 2019-11-13 07:52:19:

    1. assignee changed to: "jan.nijtmans"
    2. icomment:
      Thanks for the report. On core-8-6-10-rc this is definitely exported to work, so raising to "minor"
      
    3. login: "jan.nijtmans"
    4. mimetype: "text/plain"
    5. severity changed to: "Minor"
  5. Ticket change [ae009b62bd] (rid 176950) by jan.nijtmans on 2019-11-13 09:10:00:

    1. icomment:
      This should be fixed in [b5633ba3bd8fa74e].  Can you confirm that this fixes this? Thanks!
      
    2. login: "jan.nijtmans"
    3. mimetype: "text/x-fossil-wiki"
    4. resolution changed to: "Fixed"
    5. status changed to: "Pending"
  6. Ticket change [3ed9242a56] (rid 176951) by jan.nijtmans on 2019-11-13 09:21:36:

    1. icomment:
      Did you bisect? If you did, I guess that commit [9e1984c250d1a859] introduced this bug. This commit made it possible that TclUtfToUniChar() is called when it points to the 2nd character of a valid 4-byte UTF-8 character. The macro didn't account for that.
      
      Thanks!
      
    2. login: "jan.nijtmans"
    3. mimetype: "text/x-fossil-wiki"
  7. Ticket change [ca92f08d4b] (rid 176954) by chw on 2019-11-13 09:51:51:

    1. icomment:
      Again on Debian 9, core-8-6-branch [b5633ba3bd] using
      
        $ cd .../unix ; CC="cc -DTCL_UTF_MAX=4" ./configure --prefix=/tmp/mytcl --disable-static ; make
        $ ./tclsh
        % set X "\U1F602"
      
      the gnome-terminal hangs and the strace dump is
      
        write(1, "\360\302\230\302\230\302\202\r\n", 9)
      
      Using surrogate pair notation outputs the expected emoji
      
        % set X "\uD83D\uDE02"
      
      and strace dump is
      
        write(1, "\360\237\230\202\r\n", 6) = 6
      
      Now let's do the opposite direction
      
        % set X "\uD83D\uDE02"
        % set F [open OUT w]
        % puts -nonewline $F $X
        % close $F
        % set F [open OUT]
        % set Y [read $F] ; close $F
        % set Y
      
      the gnome-terminal hangs again and the strace dump is
      
        write(1, "\303\260\302\230\302\230\302\202\r\n", 10)
      
    2. login: "chw"
    3. mimetype: "text/plain"
  8. Ticket change [9c486b5da7] (rid 176959) by jan.nijtmans on 2019-11-13 12:39:01:

    1. icomment:
      Please, try again with [e377ac273f]. I think I really got it now ...
      
    2. login: "jan.nijtmans"
    3. mimetype: "text/plain"
  9. Ticket change [a0a66773a3] (rid 176962) by chw on 2019-11-13 14:07:20:

    1. icomment:
      Bingo! The exact same sequence I've run against [b5633ba3bd]
      now works both with "\U1F602" and "\uD83D\uDE02" notation.
      I think you can close the ticket now, thanks for fixing.
      
    2. login: "chw"
    3. mimetype: "text/plain"
  10. Ticket change [04c41202c6] (rid 176963) by jan.nijtmans on 2019-11-13 14:25:53:

    1. closedate changed to: "2458801.1013138"
    2. closer changed to: "jan.nijtmans"
    3. icomment:
      Thanks for confirming the fix! ..  And for the bug report to start with ... !!!!
      
    4. login: "jan.nijtmans"
    5. mimetype: "text/plain"
    6. status changed to: "Closed"