UTF-8 warnings

Leonard den Ottolander leonard at den.ottolander.nl
Tue Nov 2 15:28:40 UTC 2004


Hello Vladimir, Jindrich,

I'm seeing some warnings against current CVS with the UTF-8 patches. 4
"discards qualifier"s in file.c that are fixed by removing the const
qualifier from fnsource in the utf8-fix patch.

Also 1 "discard qualifier" warning in help.c. But "Unconsting" p in
help_show() does not fix this as p points to const char* paint_start.
Introducing a (redundant) cast on the call of SLsmg_write_nchars() in
the utf8-help patch. This should actually be fixed in slang.

And the last warning is: "screen.c:580: warning: passing arg 1 of
`wcswidth' from incompatible pointer type" which I fixed by casting
buffer to wchar_t in the utf8-fix patch. Should txtlen be typed to
size_t instead of int? Or would this interfere with some of the
assignments elsewhere in that code?

Also removed some redundant tabs and spaces on added "empty" lines in
the utf8-input patch, as well as a non ANSI compliant comment and
variable declarations.

Attached the whole bundle of UTF-8 patches. (These are not meant as a
proposal for upstream inclusion (yet), but FYI.)

Leonard.

-- 
mount -t life -o ro /dev/dna /genetic/research

-------------- next part --------------
A non-text attachment was scrubbed...
Name: mc-CVS-8bitdefault.patch
Type: text/x-patch
Size: 361 bytes
Desc: not available
URL: <http://lists.midnight-commander.org/pipermail/mc-devel/attachments/20041102/41b58742/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: mc-CVS-utf8-fix.patch
Type: text/x-patch
Size: 8896 bytes
Desc: not available
URL: <http://lists.midnight-commander.org/pipermail/mc-devel/attachments/20041102/41b58742/attachment-0001.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: mc-CVS-utf8-help.patch
Type: text/x-patch
Size: 1094 bytes
Desc: not available
URL: <http://lists.midnight-commander.org/pipermail/mc-devel/attachments/20041102/41b58742/attachment-0002.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: mc-CVS-utf8-hint.patch
Type: text/x-patch
Size: 1729 bytes
Desc: not available
URL: <http://lists.midnight-commander.org/pipermail/mc-devel/attachments/20041102/41b58742/attachment-0003.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: mc-CVS-utf8-input.patch
Type: text/x-patch
Size: 84846 bytes
Desc: not available
URL: <http://lists.midnight-commander.org/pipermail/mc-devel/attachments/20041102/41b58742/attachment-0004.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: mc-CVS-utf8.patch
Type: text/x-patch
Size: 45982 bytes
Desc: not available
URL: <http://lists.midnight-commander.org/pipermail/mc-devel/attachments/20041102/41b58742/attachment-0005.bin>


More information about the mc-devel mailing list