use enumerator instead of slurping it

This commit is contained in:
Akshay Karle 2015-11-18 22:49:54 -03:00
parent 8dd0434386
commit 10ef1cae8e

View file

@ -41,7 +41,7 @@ module LXC
private
def new_overlay?
@new_overlay ||= File.readlines('/proc/filesystems').include?("nodev\toverlay\n")
@new_overlay ||= File.open('/proc/filesystems').grep(/nodev\s+overlay/).any?
end
def random_mac