From 97b6966efc517825d0d6a8d25decac33bc5e4ff1 Mon Sep 17 00:00:00 2001 From: David Vazgenovich Shakaryan Date: Wed, 17 Nov 2010 01:59:05 -0800 Subject: Check if file exists instead of opening it. --- archey.new | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'archey.new') diff --git a/archey.new b/archey.new index dd157ad..b3b2521 100644 --- a/archey.new +++ b/archey.new @@ -114,7 +114,7 @@ class Output: self.distro = self.__detectDistro() def __detectDistro(self): - if open('/etc/pacman.conf'): + if os.path.exists('/etc/pacman.conf'): return 'Arch Linux' def append(self, display): -- cgit v1.2.3-54-g00ecf