bugGNU Screen - Bugs: bug #66368, Wrong UTF-8 handling of OSC xterm...

 
 

bug #66368: Wrong UTF-8 handling of OSC xterm strings

Submitter:  lvd <lvd>
Submitted:  Tue 22 Oct 2024 11:41:46 AM UTC
   
 
Category:  None Severity:  3 - Normal
Priority:  * 5 - Normal Status:  None
Privacy:  Public Assigned to:  None
Open/Closed:  Open Release:  5.0.1
Fixed Release:  None Planned Release:  None
Work Required:  None
* Mandatory Fields

Add a New Comment Rich Markup
   

Tue 22 Oct 2024 11:41:46 AM UTC, original submission:  

Reproducing:

echo -ne "\033]0;Иq\007"

where first character after ';' is U+0418, D0 98, "Cyrillic Capital Letter I".

The screen would first parse utf-8 char into an int, then put to the output string only low 8 bits of the whole unicode character.

For the given letter, a weird control code would result, that tries to break terminal (no header is set, instead garbage is printed).

Basing on bug #61032 and taking into account bug #66367, here is the patch for 5.0.0 codebase.

PS: this bug is common for UTF-8 directory names and a shell configured to put current directory name into xterm window header through xterm OSC sequence.

lvd <lvd>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

Attached Files
file #56565:  screen_5.0.0.patch added by lvd (3KiB - application/octet-stream)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by lvd (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only logged-in users can vote.

     

    Follows 1 latest change.

    Date Changed by Updated Field Previous Value => Replaced by
    2024-10-22 lvd Attached File- Added screen_5.0.0.patch, #56565

    Back to the top

    Powered by Savane 3.14-430a.
    Corresponding source code