Code

Fix compiling with --disable-locale
authorThomas Adam <thomas.adam22@gmail.com>
Mon, 30 Nov 2009 00:50:37 +0000 (00:50 +0000)
committerMax Kellermann <max@duempel.org>
Mon, 30 Nov 2009 07:56:36 +0000 (08:56 +0100)
locale_width() was previously broken when trying to compile ncmpc
without locale support.  This was due to stale code in an #if block.

Signed-off-by: Thomas Adam <thomas.adam22@gmail.com>
src/charset.c

index 01d381b5d1303d0301360a7fafc919ac1dc701db..1f51538b7f0df38abc1b1e2bdacc14bdba3201da 100644 (file)
@@ -94,7 +94,7 @@ locale_width(const char *p)
 
        return width;
 #else
-       return strlen(str);
+       return strlen(p);
 #endif
 }