GNU nano - Bugs: bug #55638, a trailing double-width character...
You are not allowed to post comments on this tracker with your current authentication level.
bug #55638: a trailing double-width character can get mistakenly printed on the next row
Submitter: | Benno Schulenberg <bens> | ||
Submitted: | Mon 04 Feb 2019 08:21:37 AM UTC | ||
Severity: | 3 - Normal | Status: | Fixed |
Assigned to: | dolorous | Open/Closed: | Closed |
Jump to the original submission
Fri 08 Mar 2019 07:06:53 PM UTC, comment #12: |
Benno Schulenberg <bens> |
Tue 05 Mar 2019 10:31:04 PM UTC, comment #11: Yes, that seems to work after some quick testing. I was reluctant to simplify it until I could verify it was working as it was. Attached new version with that simplified logic. |
David Lawrence Ramsey <dolorous> |
Tue 05 Mar 2019 07:51:04 PM UTC, comment #10: I think the logic can be reduced to:
|
Benno Schulenberg <bens> |
Mon 04 Mar 2019 09:54:43 PM UTC, comment #9: The logic is now incorrect. The attached patch against git 37c8232 covers both the case edc0d62 was meant to cover, and all the old cases.
|
David Lawrence Ramsey <dolorous> |
Wed 06 Feb 2019 09:16:10 AM UTC, comment #8: Thanks. Fixed in git, commit edc0d628. |
Benno Schulenberg <bens> |
Tue 05 Feb 2019 08:56:44 PM UTC, comment #7: Attached. |
David Lawrence Ramsey <dolorous> |
Tue 05 Feb 2019 07:41:58 PM UTC, comment #6: Ehm, no, a sign-off is not needed. I meant a normal commit patch. |
Benno Schulenberg <bens> |
Tue 05 Feb 2019 07:12:31 PM UTC, comment #5: Yeah, after going to bed last night, I realized that the *buf != '\0' part of the check prevented the trimming code from kicking in. Your change of the logic looks like the right thing. Please provide a signed-off patch. |
Benno Schulenberg <bens> |
Tue 05 Feb 2019 07:09:55 AM UTC, comment #4: Check that. I apparently misunderstood this; display_string() is more complex than I thought.
|
David Lawrence Ramsey <dolorous> |
Mon 04 Feb 2019 10:20:26 PM UTC, comment #3: After looking at the code in detail, I do. To avoid the problem, index has to be shifted far enough back that the converted is (at least) one column shorter.
|
David Lawrence Ramsey <dolorous> |
Mon 04 Feb 2019 09:16:48 AM UTC, comment #2: The offending commit is 5283acdc, "tweaks: trim a displayable string in a more efficient manner". But I don't understand why the change is wrong. |
Benno Schulenberg <bens> |
Mon 04 Feb 2019 08:24:31 AM UTC, comment #1: Oops. Reproduction recipe needs to include --nowrap:
|
Benno Schulenberg <bens> |
Mon 04 Feb 2019 08:21:37 AM UTC, original submission:
To reproduce, run 'src/nano --ignore +28 NEWS', then type three periods followed by: M-V 0 0 3 1 1 3 <Home>. Then press the space bar until the "cactus" reaches the right edge. Then type one more space. The cactus is replaced with a $, but... the ㄓ mistakenly appears at the start of the next row. Press ^L and this spurious ㄓ disappears.
|
Benno Schulenberg <bens> |
Depends on the following items: None found
Items that depend on this one: None found
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.
Follow 8 latest changes.
Date | Changed by | Updated Field | Previous Value | => | Replaced by |
---|---|---|---|---|---|
2019-03-25 | bens | Open/Closed | Open | Closed | |
2019-03-05 | dolorous | Attached File | - | Added 0001-display-fix-trims-of-double-width-characters-at-the-.patch, #46438 | |
2019-03-04 | dolorous | Attached File | - | Added 0001-display-fix-trims-of-double-width-characters-at-the-.patch, #46420 | |
2019-02-06 | bens | Status | In Progress | Fixed | |
2019-02-05 | dolorous | Attached File | - | Added 0001-display-properly-trim-double-width-characters-at-the.patch, #46186 | |
2019-02-05 | bens | Status | None | In Progress | |
Assigned to | None | dolorous | |||
2019-02-05 | dolorous | Attached File | - | Added double-width-fix.patch, #46180 |
Powered by Savane 3.13-f8d8.
Corresponding source code
The logic has been amended in master, commit 40a74e46.