We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 158bc71 commit d8980beCopy full SHA for d8980be
src/show.c
@@ -78,7 +78,8 @@ typedef enum {
78
} output_numeric_locale;
79
80
static void set_output_numeric_locale(output_numeric_locale loc) {
81
- const char *l = loc == LOCALE_PROBACKUP ? "C" : (const char*)getenv("LC_NUMERIC");
+ const char *l = loc == LOCALE_PROBACKUP ? "C" :
82
+ getenv("LC_NUMERIC") != NULL ? (const char *)getenv("LC_NUMERIC") : "C";
83
// Setting environment-specified locale
84
#ifdef HAVE_USELOCALE
85
uselocale(newlocale(LC_NUMERIC_MASK, l, (locale_t) 0));
0 commit comments