From b7a3cb6b74850ef71fbbeacbee63df791caba626 Mon Sep 17 00:00:00 2001 From: Martin Klozik Date: Wed, 9 Dec 2015 12:53:43 +0000 Subject: bugfix: Fix failure caused by unset locale In case, that VSPERF detects missing locale settings, it will set language and encodding settings to default values specified by configuration parameter DEFAULT_LOCALE. Localized external commands with output parsed by VSPERF are executed with modified locale to ensure correct VSPERF function. Locale settings for such commands is specified by configuration parameter DEFAULT_CMD_LOCALE. Change-Id: If5c15115b778ce90046e390f10438b780f82695b JIRA: VSPERF-132 Signed-off-by: Martin Klozik Reviewed-by: Maryam Tahhan Reviewed-by: Al Morton Reviewed-by: Brian Castelli Reviewed-by: Gurpreet Singh Reviewed-by: Tv Rao --- vnfs/qemu/qemu.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'vnfs/qemu/qemu.py') diff --git a/vnfs/qemu/qemu.py b/vnfs/qemu/qemu.py index 4b0bf0b2..f292d7d9 100644 --- a/vnfs/qemu/qemu.py +++ b/vnfs/qemu/qemu.py @@ -163,7 +163,7 @@ class IVnfQemu(IVnf): self._logger.info('Affinitizing guest...') - cur_locale = locale.getlocale()[1] + cur_locale = locale.getdefaultlocale()[1] proc = subprocess.Popen( ('echo', 'info cpus'), stdout=subprocess.PIPE) output = subprocess.check_output( -- cgit 1.2.3-korg