At 1243318849 time_t, Ángel Alonso wrote: > From 92761316de40b0cac70dd5eca34ed72d7a84e07c Mon Sep 17 00:00:00 2001 > From: feler <fe...@archlinux.us> > Date: Tue, 26 May 2009 22:40:20 -0700 > Subject: [PATCH] warning_setlocale > > --- > awesome.c | 3 ++- > 1 files changed, 2 insertions(+), 1 deletions(-) > > diff --git a/awesome.c b/awesome.c > index 321d98e..e6672e6 100644 > --- a/awesome.c > +++ b/awesome.c > @@ -354,7 +354,8 @@ main(int argc, char **argv) > } > > /* Text won't be printed correctly otherwise */ > - setlocale(LC_CTYPE, ""); > + if(!setlocale(LC_CTYPE, "")) > + fprintf(stderr, "warning: cannot set locale.\n");
You should rather use warn(). Btw, does this situation really happens and has any impact? Cheers, -- Julien Danjou // ᐰ <jul...@danjou.info> http://julien.danjou.info // 9A0D 5FD9 EB42 22F6 8974 C95C A462 B51E C2FE E5CD // The more we fly, the more we climb, the more we know that heaven is a lie.
signature.asc
Description: Digital signature