mirror of
https://github.com/OpenNebula/one.git
synced 2025-01-11 05:17:41 +03:00
Merge branch 'mattthias-master_check_for_unreadable_image'
This commit is contained in:
commit
18c2d993e1
@ -86,10 +86,10 @@ class OneImageHelper < OpenNebulaHelper::OneHelper
|
||||
path=Dir.pwd+"/"+o
|
||||
end
|
||||
|
||||
if File.exist?(path)
|
||||
if File.readable?(path)
|
||||
[0, path]
|
||||
else
|
||||
[-1, "File '#{path}' does not exist."]
|
||||
[-1, "File '#{path}' does not exist or is not readable."]
|
||||
end
|
||||
end
|
||||
},
|
||||
|
Loading…
Reference in New Issue
Block a user