From be3a828e7057e2ea01772b2a00d2ad3e5c46776c Mon Sep 17 00:00:00 2001 From: Marcus Brinkmann Date: Fri, 7 May 2010 01:32:54 +0000 Subject: 2010-05-07 Marcus Brinkmann * engine-g13.c, gpgme.c, engine-gpgsm.c, engine-gpg.c, op-support.c, engine-assuan.c, gpgme-tool.c: Include only if available with HAVE_LOCALE_H and conditionalize use of LC_CTYPE on its definition. * engine-gpgconf.c: Do not include . --- src/gpgme.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/gpgme.c') diff --git a/src/gpgme.c b/src/gpgme.c index fe601a09..b6a518ff 100644 --- a/src/gpgme.c +++ b/src/gpgme.c @@ -27,7 +27,9 @@ #include #include #include +#ifdef HAVE_LOCALE_H #include +#endif #include "util.h" #include "context.h" @@ -600,7 +602,9 @@ gpgme_set_locale (gpgme_ctx_t ctx, int category, const char *value) failed = 1; \ } +#ifdef LC_CTYPE PREPARE_ONE_LOCALE (ctype, CTYPE); +#endif #ifdef LC_MESSAGES PREPARE_ONE_LOCALE (messages, MESSAGES); #endif @@ -636,7 +640,9 @@ gpgme_set_locale (gpgme_ctx_t ctx, int category, const char *value) if (!ctx) LOCK (def_lc_lock); +#ifdef LC_CTYPE SET_ONE_LOCALE (ctype, CTYPE); +#endif #ifdef LC_MESSAGES SET_ONE_LOCALE (messages, MESSAGES); #endif -- cgit v1.2.3