[systemd-commits] src/test
Thomas H.P. Andersen
phomes at kemper.freedesktop.org
Tue Apr 7 11:54:36 PDT 2015
src/test/test-util.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
New commits:
commit 5d84c44a976794625889f3d24e57835d5de234e3
Author: Thomas Hindoe Paaboel Andersen <phomes at gmail.com>
Date: Tue Apr 7 20:28:27 2015 +0200
test-util: don't mix declarations and code
diff --git a/src/test/test-util.c b/src/test/test-util.c
index aaf25f8..052e292 100644
--- a/src/test/test-util.c
+++ b/src/test/test-util.c
@@ -416,10 +416,10 @@ static void test_cescape(void) {
static void test_cunescape(void) {
_cleanup_free_ char *unescaped;
+ const char *x = "abc\\\"\b\f\a\n\r\t\v\003\177\234\313\\000\\x00";
assert_se(cunescape("abc\\\\\\\"\\b\\f\\a\\n\\r\\t\\v\\003\\177\\234\\313\\000\\x00", 0, &unescaped) < 0);
assert_se(cunescape("abc\\\\\\\"\\b\\f\\a\\n\\r\\t\\v\\003\\177\\234\\313\\000\\x00", UNESCAPE_RELAX, &unescaped) >= 0);
- const char *x = "abc\\\"\b\f\a\n\r\t\v\003\177\234\313\\000\\x00";
assert_se(streq_ptr(unescaped, x));
free(unescaped);
unescaped = NULL;
More information about the systemd-commits
mailing list