diff options
author | Sébastien Helleu <flashcode@flashtux.org> | 2015-08-24 11:05:31 +0200 |
---|---|---|
committer | Sébastien Helleu <flashcode@flashtux.org> | 2015-08-24 11:05:31 +0200 |
commit | 41cb1bf635eb56b7189dbfbdb89432dca1f46ede (patch) | |
tree | 7741fd1b405d0ce934433033d2cfdfa06af534cc /tests/unit/core | |
parent | c8ac75601f0c0003c7ec0bf6605bd6e2258ab5a3 (diff) | |
download | weechat-41cb1bf635eb56b7189dbfbdb89432dca1f46ede.zip |
api: fix handle of invalid escape in function string_convert_escaped_chars()
And a new test is now checking that "\" returns "".
Diffstat (limited to 'tests/unit/core')
-rw-r--r-- | tests/unit/core/test-string.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/tests/unit/core/test-string.cpp b/tests/unit/core/test-string.cpp index dc33029cd..cf1a6c464 100644 --- a/tests/unit/core/test-string.cpp +++ b/tests/unit/core/test-string.cpp @@ -460,6 +460,7 @@ TEST(String, ConvertEscapedChars) WEE_TEST_STR(NULL, string_convert_escaped_chars (NULL)); WEE_TEST_STR("", string_convert_escaped_chars ("")); + WEE_TEST_STR("", string_convert_escaped_chars ("\\")); WEE_TEST_STR("\"", string_convert_escaped_chars ("\\\"")); WEE_TEST_STR("\\", string_convert_escaped_chars ("\\\\")); WEE_TEST_STR("\a", string_convert_escaped_chars ("\\a")); |