FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Redhat > Fedora SELinux Support

 
 
LinkBack Thread Tools
 
Old 03-05-2009, 01:41 PM
Chris Lumens
 
Default Add a get() method to Flags, since it pretends to be a dictionary.

---
flags.py | 6 ++++++
1 files changed, 6 insertions(+), 0 deletions(-)

diff --git a/flags.py b/flags.py
index 2d77bd7..8dbcc9f 100644
--- a/flags.py
+++ b/flags.py
@@ -36,6 +36,12 @@ class Flags:
else:
raise AttributeError, attr

+ def get(self, attr, val=None):
+ if self.__dict__['flags'].has_key(attr):
+ return self.__dict__['flags'][attr]
+ else:
+ return val
+
def createCmdlineDict(self):
cmdlineDict = {}
cmdline = open("/proc/cmdline", "r").read().strip()
--
1.6.1.3

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@redhat.com
https://www.redhat.com/mailman/listinfo/anaconda-devel-list
 

Thread Tools




All times are GMT. The time now is 06:43 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright 2007 - 2008, www.linux-archive.org