summaryrefslogtreecommitdiff
path: root/usr/src/cmd/pyzfs
diff options
context:
space:
mode:
authorSam Falkner <Sam.Falkner@Sun.COM>2010-02-25 11:47:05 -0700
committerSam Falkner <Sam.Falkner@Sun.COM>2010-02-25 11:47:05 -0700
commite4d060fb4c00d44cd578713eb9a921f594b733b8 (patch)
treec38276f18cf33dbd25c1451f4d3a92ef8adfc6b3 /usr/src/cmd/pyzfs
parente69acc927b15c46de46ae637e53e1b808990a5bc (diff)
downloadillumos-gate-e4d060fb4c00d44cd578713eb9a921f594b733b8.tar.gz
6895223 zfs userspace/groupspace/allow/unallow/holds IOError in Japanese locale
Diffstat (limited to 'usr/src/cmd/pyzfs')
-rw-r--r--usr/src/cmd/pyzfs/pyzfs.py10
1 files changed, 7 insertions, 3 deletions
diff --git a/usr/src/cmd/pyzfs/pyzfs.py b/usr/src/cmd/pyzfs/pyzfs.py
index 3867d91ccd..973ffc4dc1 100644
--- a/usr/src/cmd/pyzfs/pyzfs.py
+++ b/usr/src/cmd/pyzfs/pyzfs.py
@@ -19,7 +19,7 @@
#
# CDDL HEADER END
#
-# Copyright 2009 Sun Microsystems, Inc. All rights reserved.
+# Copyright 2010 Sun Microsystems, Inc. All rights reserved.
# Use is subject to license terms.
#
@@ -36,13 +36,17 @@ try:
import zfs.ioctl
import sys
import errno
+ import solaris.misc
"""This is the main script for doing zfs subcommands. It doesn't know
what subcommands there are, it just looks for a module zfs.<subcommand>
that implements that subcommand."""
- _ = gettext.translation("SUNW_OST_OSCMD", "/usr/lib/locale",
- fallback=True).gettext
+ try:
+ _ = gettext.translation("SUNW_OST_OSCMD", "/usr/lib/locale",
+ fallback=True).gettext
+ except:
+ _ = solaris.misc.gettext
if len(sys.argv) < 2:
sys.exit(_("missing subcommand argument"))