From 8b9f33e040b5ddb7ee2fef072410f77afb528ea6 Mon Sep 17 00:00:00 2001 From: Joe Groff Date: Wed, 12 May 2010 18:07:33 -0700 Subject: [PATCH] x11: convert XSupportsLocale return value to factor bool before testing (bug reported by ceninan) --- basis/x11/x11.factor | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/basis/x11/x11.factor b/basis/x11/x11.factor index 67c94c88ea..d32eaca47e 100644 --- a/basis/x11/x11.factor +++ b/basis/x11/x11.factor @@ -3,6 +3,7 @@ USING: alien.strings continuations io io.encodings.ascii kernel namespaces x11.xlib x11.io vocabs vocabs.loader ; +FROM: alien.c-types => c-bool> ; IN: x11 SYMBOL: dpy @@ -11,7 +12,7 @@ SYMBOL: root : init-locale ( -- ) LC_ALL "" setlocale [ "setlocale() failed" print flush ] unless - XSupportsLocale [ "XSupportsLocale() failed" print flush ] unless ; + XSupportsLocale c-bool> [ "XSupportsLocale() failed" print flush ] unless ; : flush-dpy ( -- ) dpy get XFlush drop ;