FS#48347 - [cowsay] Unicode string lengths are calculated incorrectly

Attached to Project: Arch Linux
Opened by Dmitry V. Luciv (dluciv) - Friday, 26 February 2016, 13:14 GMT
Last edited by T.J. Townsend (blakkheim) - Wednesday, 20 September 2023, 03:03 GMT
Task Type Bug Report
Category Upstream Bugs
Status Closed
Assigned To Levente Polyak (anthraxx)
T.J. Townsend (blakkheim)
Architecture All
Severity Medium
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:

$ cowsay Привет

prints:

______________
< Привет >
--------------
\ ^__^
\ (oo)\_______
(__)\ )\/\
||----w |
|| ||


Showing that one cyrillic letter is calculated as two (due to UTF-8).

Additional info:
* package version: 3.03-9, but the problem was here for ages.

For example, Gentoo patches cowsay when building it. I guess this can help here: https://gitweb.gentoo.org/repo/gentoo.git/tree/games-misc/cowsay/cowsay-3.03-r2.ebuild

Steps to reproduce:

$ cowsay Привет

This task depends upon

Closed by  T.J. Townsend (blakkheim)
Wednesday, 20 September 2023, 03:03 GMT
Reason for closing:  Fixed
Comment by Dmitry V. Luciv (dluciv) - Friday, 26 February 2016, 13:18 GMT Comment by Dessa Simpson (virtualdxs) - Monday, 24 December 2018, 23:29 GMT
Any timeline on this being fixed? Seems to still be an issue.
Comment by Dane Johnson (SweetDee) - Tuesday, 01 September 2020, 18:23 GMT
Patch based on ubuntu fix
Comment by Buggy McBugFace (bugbot) - Tuesday, 08 August 2023, 19:11 GMT
This is an automated comment as this bug is open for more then 2 years. Please reply if you still experience this bug otherwise this issue will be closed after 1 month.

Loading...