diff --git a/ChangeLog b/ChangeLog index 7e335de6df3d1aa07712b5e97c9daaab97be1aa6..eccda55073a58bc5a7337d4e7bf2ec94b08302d6 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2014-04-08 David Lawrence Ramsey <pooka109@gmail.com> + * src/nano.c (main): Convert the literal UTF-8 whitespace string into + its corresponding byte sequence, and add a comment for it. + 2014-04-08 Benno Schulenberg <bensberg@justemail.net> * src/rcfile.c (parse_binding): Melt the binding and unbinding code, which are very similar, into a single function. diff --git a/src/nano.c b/src/nano.c index de3b5c819728d5bbf0a4878db0ed52c5596b4510..d2755e73ce85aa8a7af39c450b634196291176c4 100644 --- a/src/nano.c +++ b/src/nano.c @@ -2595,11 +2595,14 @@ int main(int argc, char **argv) matchbrackets = mallocstrcpy(NULL, "(<[{)>]}"); #ifdef ENABLE_NANORC - /* If whitespace wasn't specified, set its default value. */ + /* If whitespace wasn't specified, set its default value. If we're + * using UTF-8, it's Unicode 00BB (Right-Pointing Double Angle + * Quotation Mark) and Unicode 00B7 (Middle Dot). Otherwise, it's + * ">" and ".". */ if (whitespace == NULL) { #ifdef ENABLE_UTF8 if (using_utf8()) { - whitespace = mallocstrcpy(NULL, "»·"); + whitespace = mallocstrcpy(NULL, "\xC2\xBB\xC2\xB7"); whitespace_len[0] = 2; whitespace_len[1] = 2; } else