summaryrefslogtreecommitdiff
path: root/SoftwareProperties/aptsources.py
diff options
context:
space:
mode:
authorMichael Vogt <egon@top>2005-11-29 17:31:21 +0100
committerMichael Vogt <egon@top>2005-11-29 17:31:21 +0100
commita79e4fc80ef854844e560e5b547d1398ab149360 (patch)
treee321ca95a5573529a4261ca1fdbd01b14c4a17af /SoftwareProperties/aptsources.py
parent4fce0fdfe15c8ab88d63e3919670e1371eb38fb9 (diff)
downloadpython-apt-a79e4fc80ef854844e560e5b547d1398ab149360.tar.gz
* make the software preferences work again completely
Diffstat (limited to 'SoftwareProperties/aptsources.py')
-rw-r--r--SoftwareProperties/aptsources.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/SoftwareProperties/aptsources.py b/SoftwareProperties/aptsources.py
index 640a70b4..aa3cbb5a 100644
--- a/SoftwareProperties/aptsources.py
+++ b/SoftwareProperties/aptsources.py
@@ -27,12 +27,12 @@ import re
import apt_pkg
import glob
-from DistInfo import DistInfo
+from UpdateManager.Common.DistInfo import DistInfo
# actual source.list entries
class SourceEntry:
- def __init__(self, line,file):
+ def __init__(self, line,file=None):
self.invalid = False
self.disabled = False
self.type = ""
@@ -41,6 +41,8 @@ class SourceEntry:
self.comps = []
self.comment = ""
self.line = line
+ if file == None:
+ file = apt_pkg.Config.FindDir("Dir::Etc")+apt_pkg.Config.Find("Dir::Etc::sourcelist")
self.file = file
self.parse(line)