On Fri, Sep 24, 2010 at 07:28:08PM +0100, Steven Chamberlain wrote: > On 24/09/10 18:33, Steven Chamberlain wrote: > >>python/acquire.cc: In function 'PyObject* PkgAcquireNew(PyTypeObject*, > >>PyObject*, PyObject*)': > >>python/acquire.cc:331: warning: > >>'pkgAcquire::pkgAcquire(pkgAcquireStatus*)' is deprecated (declared at > >>/usr/include/apt-pkg/acquire.h:352) > > Actually, here's our culprint: > > >python/acquire-item.cc: In function 'PyObject* acquireitem_repr(PyObject*)': > >python/acquire-item.cc:170: warning: format '%lu' expects type 'long > >unsigned int', but argument 7 has type 'long long unsigned int' > > A 'long unsigned int' became a 'long long unsigned int', but on > amd64 those data types are the same, which is why we only saw an > issue on i386. [..]
It turns out that there are two more issues in the code, I attached a updated patch. Could you please give it a try and see if its good or causing any issues? Thanks, Michael
=== modified file 'python/acquire-item.cc' --- python/acquire-item.cc 2010-06-01 15:14:30 +0000 +++ python/acquire-item.cc 2010-09-24 19:25:37 +0000 @@ -65,7 +65,7 @@ static PyObject *acquireitem_get_filesize(PyObject *self, void *closure) { pkgAcquire::Item *item = acquireitem_tocpp(self); - return item ? Py_BuildValue("i", item->FileSize) : 0; + return item ? Py_BuildValue("K", item->FileSize) : 0; } static PyObject *acquireitem_get_id(PyObject *self, void *closure) @@ -95,7 +95,7 @@ static PyObject *acquireitem_get_partialsize(PyObject *self, void *closure) { pkgAcquire::Item *item = acquireitem_tocpp(self); - return item ? Py_BuildValue("i", item->PartialSize) : 0; + return item ? Py_BuildValue("K", item->PartialSize) : 0; } static PyObject *acquireitem_get_status(PyObject *self, void *closure) @@ -162,7 +162,7 @@ return 0; return PyString_FromFormat("<%s object: " "Status: %i Complete: %i Local: %i IsTrusted: %i " - "FileSize: %lu DestFile:'%s' " + "FileSize: %llu DestFile:'%s' " "DescURI: '%s' ID:%lu ErrorText: '%s'>", Self->ob_type->tp_name, Itm->Status, Itm->Complete, Itm->Local, Itm->IsTrusted(),