Module Name:    src
Committed By:   yamt
Date:           Mon Apr 22 13:27:49 UTC 2013

Modified Files:
        src/share/examples/puffs/pgfs: mount.c

Log Message:
do setlocale so that we can print localized messages from libpq correctly.


To generate a diff of this commit:
cvs rdiff -u -r1.2 -r1.3 src/share/examples/puffs/pgfs/mount.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/share/examples/puffs/pgfs/mount.c
diff -u src/share/examples/puffs/pgfs/mount.c:1.2 src/share/examples/puffs/pgfs/mount.c:1.3
--- src/share/examples/puffs/pgfs/mount.c:1.2	Wed Apr 11 14:25:54 2012
+++ src/share/examples/puffs/pgfs/mount.c	Mon Apr 22 13:27:49 2013
@@ -1,4 +1,4 @@
-/*	$NetBSD: mount.c,v 1.2 2012/04/11 14:25:54 yamt Exp $	*/
+/*	$NetBSD: mount.c,v 1.3 2013/04/22 13:27:49 yamt Exp $	*/
 
 /*-
  * Copyright (c)2010,2011 YAMAMOTO Takashi,
@@ -28,11 +28,12 @@
 
 #include <sys/cdefs.h>
 #ifndef lint
-__RCSID("$NetBSD: mount.c,v 1.2 2012/04/11 14:25:54 yamt Exp $");
+__RCSID("$NetBSD: mount.c,v 1.3 2013/04/22 13:27:49 yamt Exp $");
 #endif /* not lint */
 
 #include <err.h>
 #include <errno.h>
+#include <locale.h>
 #include <mntopts.h>
 #include <paths.h>
 #include <puffs.h>
@@ -78,6 +79,8 @@ main(int argc, char *argv[])
 	bool debug = false;
 	bool dosync;
 
+	setlocale(LC_ALL, "");
+
 	mntflags = 0;
 	altmntflags = 0;
 	while ((ch = getopt(argc, argv, "o:")) != -1) {

Reply via email to