Commit 82a41107 authored by Chris Allegretta's avatar Chris Allegretta
Browse files

2014-05-29 Chris Allegretta <chrisa@asty.org>

        * src/chars.c (addstrings): Needs to be available even on
          non-utf-8 sustems.
        * nano-regress: Added --disable-utf8 to regression check



git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4933 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
No related merge requests found
Showing with 18 additions and 12 deletions
+18 -12
2014-05-29 Chris Allegretta <chrisa@asty.org>
* src/chars.c (addstrings): Needs to be available even on
non-utf-8 sustems.
* nano-regress: Added --disable-utf8 to regression check
2014-05-28 Chris Allegretta <chrisa@asty.org> 2014-05-28 Chris Allegretta <chrisa@asty.org>
* doc/syntax/mutt.nanorc: Include Benno's awesome signature * doc/syntax/mutt.nanorc: Include Benno's awesome signature
matcher, modified slightly to also work for quoted sigs. matcher, modified slightly to also work for quoted sigs.
......
...@@ -8,7 +8,7 @@ sub combinations { ...@@ -8,7 +8,7 @@ sub combinations {
return @rest, map { [$first, @$_] } @rest; return @rest, map { [$first, @$_] } @rest;
} }
my @allargs=("--enable-debug", "--disable-wrapping", "--disable-justify", "--disable-extra", "--enable-tiny", "--disable-browser --disable-help --disable-mouse --disable-operatingdir --disable-speller", "--disable-multibuffer", "--disable-nanorc", "--with-slang"); my @allargs=("--enable-debug", "--disable-wrapping", "--disable-justify", "--disable-extra", "--enable-tiny", "--disable-utf8", "--disable-multibuffer", "--disable-nanorc", "--with-slang");
my @combos = combinations(@allargs); my @combos = combinations(@allargs);
my $i = 0; my $i = 0;
......
...@@ -43,17 +43,6 @@ static const wchar_t bad_wchar = 0xFFFD; ...@@ -43,17 +43,6 @@ static const wchar_t bad_wchar = 0xFFFD;
static const char *const bad_mbchar = "\xEF\xBF\xBD"; static const char *const bad_mbchar = "\xEF\xBF\xBD";
static const int bad_mbchar_len = 3; static const int bad_mbchar_len = 3;
/* Concatenate two allocated strings. */
char* addstrings(char* str1, size_t len1, char* str2, size_t len2)
{
str1 = charealloc(str1, len1 + len2 + 1);
str1[len1] = '\0';
strncat(&str1[len1], str2, len2);
free(str2);
return str1;
}
/* Enable UTF-8 support. */ /* Enable UTF-8 support. */
void utf8_init(void) void utf8_init(void)
{ {
...@@ -67,6 +56,18 @@ bool using_utf8(void) ...@@ -67,6 +56,18 @@ bool using_utf8(void)
} }
#endif /* ENABLE_UTF8 */ #endif /* ENABLE_UTF8 */
/* Concatenate two allocated strings. */
char* addstrings(char* str1, size_t len1, char* str2, size_t len2)
{
str1 = charealloc(str1, len1 + len2 + 1);
str1[len1] = '\0';
strncat(&str1[len1], str2, len2);
free(str2);
return str1;
}
#ifndef HAVE_ISBLANK #ifndef HAVE_ISBLANK
/* This function is equivalent to isblank(). */ /* This function is equivalent to isblank(). */
bool nisblank(int c) bool nisblank(int c)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment