2014-11-26 11:13 GMT+01:00 Jan Nijtmans <jan.nijtm...@gmail.com>: > See: > <http://www.fossil-scm.org/index.html/info/f2fc37c063> > > Thanks for your report!
A related problem on win32: C:\Users\me>fossil cat test/utf16be.txt �� T h i s f i l e c o n t a i n s u t f - 1 6 b e t e x t . T h e p u r p o s e f o r i n c l u d i n g t h i s f i l e i n t h e F o s s i l r e p o s i t o r y i s t o p r o v i d e t h e a b i l i t y t o t e s t F o s s i l ' s h a n d l i n g o f U T F - 1 6 u s i n g i t s o w n r e p o s i t o r y . B r o w s i n g t o t h i s f i l e i n t h e w e b i n t e r f a c e s h o u l d d i s p l a y t h e f i l e a s t e x t o n t h e s c r e e n . W h e n t h e r e a r e c h a n g e s t o t h i s f i l e t h o s e c h a n g e s s h o u l d s h o w u p i n t h e " d i f f " o u t p u t a n d b e p r o p e r l y d i s p l a y e d o n t h e s c r e e n . T e s t p r o c e d u r e s : 1 . V e r i f y t h a t t h i s f i l e i s c o r r e c t l y d i s p l a y u s i n g t h e / a r t i f a c t w e b p a g e . 2 . V e r i f y t h a t t h i s f i l e i s c o r r e c t l y d i s p l a y e d b y t h e / d o c w e b pa g e . 3 . V e r i f y t h a t c h a n g e s t o a r e c o r r e c t l y d i s p l a y e d b y t h e / f d i f f w e b p a g e . 4 . V e r i f y t h a t t h e " f o s s i l d i f f " c o m m a n d c o r r e c t l y d i s p l a y s c h a n g e s i n t h i s f i l e . D o t h e s a m e w i t h t h e - - t k o p t i o n . Converting a blob from UTF-8 to Unicode, before writing it to the console, is not a good idea if we are not sure the blob is really in UTF-8..... (in this example it's not so bad, because 0-bytes are apparently converted to spaces, but the result could have been be much worse if every non-valid byte sequence is displayed as ��) Fix here: <http://www.fossil-scm.org/index.html/info/156ef9ec06> Note: of course, special handling should only be done when really writing to the windows console, not when the console is redirected to a file. Regards, Jan Nijtmans _______________________________________________ fossil-users mailing list fossil-users@lists.fossil-scm.org http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users