From c62373c1096cf1060dd86e33584f708d0cf2d4c9 Mon Sep 17 00:00:00 2001 From: Jan Kaluza Date: Wed, 9 May 2012 10:04:06 +0200 Subject: [PATCH] Fixed switch_profile --- tuned/controller.py | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/tuned/controller.py b/tuned/controller.py index 88b87c1..0a78c01 100644 --- a/tuned/controller.py +++ b/tuned/controller.py @@ -112,14 +112,10 @@ class Controller(exports.interfaces.ExportableInterface): @exports.export("as", "b") def switch_profile(self, profiles): - - print profiles - - return False - - cfg = profile.Profile.find_profile(profile) + for i in range(len(profiles)): + profiles[i] = profile.Profile.find_profile(profiles[i]) try: - self.config_file = cfg + self.config_file = profiles except ValueError as e: log.error("Unable to open profile's config file %s" % (cfg) ) return False