[node-patches] Change in ovirt-node[master]: installer: Fix logging output
mburns at redhat.com
mburns at redhat.com
Tue Jan 29 13:48:24 UTC 2013
Hello Fabian Deutsch,
I'd like you to do a code review. Please visit
http://gerrit.ovirt.org/11501
to review the following change.
Change subject: installer: Fix logging output
......................................................................
installer: Fix logging output
Fix for commit 201e2e8a4f2bf88c142e3bb6a419ad61e3eeba31
os.path.exists raises an Exception if it's argument is None.
Change-Id: I83b7ffe6f8232aa6e237dc2d90bbf2239c504f49
Signed-off-by: Fabian Deutsch <fabiand at redhat.com>
---
M scripts/ovirtnode/install.py
1 file changed, 3 insertions(+), 2 deletions(-)
git pull ssh://gerrit.ovirt.org:29418/ovirt-node refs/changes/01/11501/1
diff --git a/scripts/ovirtnode/install.py b/scripts/ovirtnode/install.py
index 474f7e5..b2578e8 100755
--- a/scripts/ovirtnode/install.py
+++ b/scripts/ovirtnode/install.py
@@ -275,9 +275,10 @@
logger.debug(str(os.listdir("/liveos")))
grub_config_file = "/liveos/EFI/redhat/grub.conf"
mount_efi(target="/liveos")
+ grub_config_file_exists = grub_config_file is not None and os.path.exists(grub_config_file)
logger.debug("Grub config file is: %s" % grub_config_file)
- logger.debug("Grub config file exists: " + str(os.path.exists(grub_config_file)))
- if not grub_config_file is None and os.path.exists(grub_config_file):
+ logger.debug("Grub config file exists: %s" % grub_config_file_exists)
+ if grub_config_file_exists:
f=open(grub_config_file)
oldgrub=f.read()
f.close()
--
To view, visit http://gerrit.ovirt.org/11501
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I83b7ffe6f8232aa6e237dc2d90bbf2239c504f49
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-node
Gerrit-Branch: master
Gerrit-Owner: Michael Burns <mburns at redhat.com>
Gerrit-Reviewer: Fabian Deutsch <fabiand at fedoraproject.org>
More information about the node-patches
mailing list