summaryrefslogtreecommitdiff
path: root/python
diff options
context:
space:
mode:
authorMichael Vogt <michael.vogt@ubuntu.com>2005-07-01 22:32:51 +0000
committerMichael Vogt <michael.vogt@ubuntu.com>2005-07-01 22:32:51 +0000
commit629e715d6212d57003a1276773537458943b2ad0 (patch)
tree6a1fbc3bde5e6b8e4a0547dd54930151c2b1fef7 /python
parenta1c38f628ef497e196cfebb9677dbf687dc13f1c (diff)
downloadpython-apt-629e715d6212d57003a1276773537458943b2ad0.tar.gz
* added "Downloadable" as attribute to a VerIterator
Diffstat (limited to 'python')
-rw-r--r--python/cache.cc4
-rw-r--r--python/depcache.cc1
2 files changed, 4 insertions, 1 deletions
diff --git a/python/cache.cc b/python/cache.cc
index a8e4bfd9..4fb3d389 100644
--- a/python/cache.cc
+++ b/python/cache.cc
@@ -546,7 +546,9 @@ static PyObject *VersionAttr(PyObject *Self,char *Name)
return Py_BuildValue("i",Ver->Priority);
else if (strcmp("PriorityStr",Name) == 0)
return PyString_FromString(Ver.PriorityType());
-
+ else if (strcmp("Downloadable", Name) == 0)
+ return Py_BuildValue("b", Ver.Downloadable());
+
PyErr_SetString(PyExc_AttributeError,Name);
return 0;
}
diff --git a/python/depcache.cc b/python/depcache.cc
index 2d7161a3..418ddd14 100644
--- a/python/depcache.cc
+++ b/python/depcache.cc
@@ -401,6 +401,7 @@ static PyObject *PkgDepCacheMarkedInstall(PyObject *Self,PyObject *Args)
return HandleErrors(Py_BuildValue("b",state.NewInstall()));
}
+
static PyObject *PkgDepCacheMarkedUpgrade(PyObject *Self,PyObject *Args)
{
pkgDepCache *depcache = GetCpp<pkgDepCache *>(Self);