From df37291a5198818e5bb1d11c34ba134aa3d79d96 Mon Sep 17 00:00:00 2001 From: Mike Kelly Date: Fri, 1 Oct 2010 19:58:07 -0400 Subject: unit-name: fix unit name escaping we want to do a bitwise shift, not a greater-than comparision --- src/unit-name.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/unit-name.c') diff --git a/src/unit-name.c b/src/unit-name.c index 2e2948ab1d..868d13e4c9 100644 --- a/src/unit-name.c +++ b/src/unit-name.c @@ -211,7 +211,7 @@ static char* do_escape(const char *f, char *t) { else if (*f == '-' || *f == '\\' || !strchr(VALID_CHARS, *f)) { *(t++) = '\\'; *(t++) = 'x'; - *(t++) = hexchar(*f > 4); + *(t++) = hexchar(*f >> 4); *(t++) = hexchar(*f); } else *(t++) = *f; -- cgit v1.2.3-54-g00ecf