[node-patches] Change in ovirt-node[master]: make sure the repo is file before mount it.

hadong0720 at gmail.com hadong0720 at gmail.com
Mon Sep 15 06:47:24 UTC 2014


hadong has uploaded a new change for review.

Change subject: make sure the repo is file before mount it.
......................................................................

make sure the repo is file before mount it.

Change-Id: Id033c87eb2d8723c43d06e74fdcf5e1f18d2d52f
Bug-Url:https://bugzilla.redhat.com/show_bug.cgi?id=1141653
Signed-off-by: hadong <hadong at redhat.com>
---
M tools/edit-node
1 file changed, 2 insertions(+), 1 deletion(-)


  git pull ssh://gerrit.ovirt.org:29418/ovirt-node refs/changes/16/32916/1

diff --git a/tools/edit-node b/tools/edit-node
index db5f965..7bc266d 100755
--- a/tools/edit-node
+++ b/tools/edit-node
@@ -1037,7 +1037,8 @@
                 return True
             elif os.path.isdir(options.repo) or \
                     options.repo.lower().endswith(".iso"):
-                if options.repo.lower().endswith(".iso"):
+                if options.repo.lower().endswith(".iso") and \
+                    os.path.isfile(options.repo):
                     cmd = "mount -o loop %s %s" % (options.repo, self.dd_dir)
                     f = subprocess.Popen(cmd, shell=True, stdout=PIPE,
                                          stderr=STDOUT)


-- 
To view, visit http://gerrit.ovirt.org/32916
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Id033c87eb2d8723c43d06e74fdcf5e1f18d2d52f
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-node
Gerrit-Branch: master
Gerrit-Owner: hadong <hadong0720 at gmail.com>



More information about the node-patches mailing list