screen-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[screen-devel] [bug #51890] screen randomly injects \b into UTF8 streams


From: Egmont Koblinger
Subject: [screen-devel] [bug #51890] screen randomly injects \b into UTF8 streams when processing combining characters
Date: Sun, 26 Nov 2017 08:40:48 -0500 (EST)
User-agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:56.0) Gecko/20100101 Firefox/56.0

Follow-up Comment #4, bug #51890 (project screen):

Mike, does this behavior cause any actual bug? Looks to me that it should be
harmless.

My wild guess is:

It could be related to https://bugzilla.gnome.org/show_bug.cgi?id=673981
bullet point 3, and the varying behavior of terminal emulators in that case.

When screen sees the first "A", it decides that it needs to print that, and
does so.

When it encounters the combining accent, it updates its internal concept about
the screen contents: it's no longer an A but an A with some combining accent.

Maybe it totally forgets that there was already an "A" printed that could be
reused. Or maybe it still recalls that there's an "A" there, but didn't keep
track whether the cursor was perhaps moved away (e.g. to update something on a
different pane) and then moved back, according to the bullet point 3 of the
aforementoned bug. Either case, it cannot be sure that simply printing the
combining accent will properly go over the corresponding base character, so
decides to reprint the character.

So it's not necessarily an explicit '\b' for this purpose somewhere in the
source, maybe it's just the simplest way of moving the cursor to that desired
place.

screen should, however, probably consume the entire input in a single step,
and then update the canvas in another single one, in which case this trick
wouldn't be necessary.

All these are just a random guess from me, without knowing anything about
screen's internals. I just guess that the real explanation might be somewhere
along these lines.

    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?51890>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]