diff options
author | Guillem Jover <guillem@debian.org> | 2012-02-04 15:11:13 +0100 |
---|---|---|
committer | Guillem Jover <guillem@debian.org> | 2012-02-05 21:29:34 +0100 |
commit | de78783d962d2511dd8dd1dd34c4a0d03912ec2d (patch) | |
tree | 9d87cf77bb78b781cf44d058a582b056a16268bc /src | |
parent | cd3fafbdaaaecfd7f7e4fdf681cb831cc19a41b2 (diff) | |
download | dpkg-de78783d962d2511dd8dd1dd34c4a0d03912ec2d.tar.gz |
libdpkg: Pass struct pkgbin to pkg_summary()
Diffstat (limited to 'src')
-rw-r--r-- | src/enquiry.c | 3 | ||||
-rw-r--r-- | src/querycmd.c | 6 |
2 files changed, 5 insertions, 4 deletions
diff --git a/src/enquiry.c b/src/enquiry.c index c90689e14..265d77b8c 100644 --- a/src/enquiry.c +++ b/src/enquiry.c @@ -3,6 +3,7 @@ * enquiry.c - status enquiry and listing options * * Copyright © 1995,1996 Ian Jackson <ian@chiark.greenend.org.uk> + * Copyright © 2006,2008-2012 Guillem Jover <guillem@debian.org> * Copyright © 2011 Linaro Limited * Copyright © 2011 Raphaël Hertzog <hertzog@debian.org> * @@ -147,7 +148,7 @@ static void describebriefly(struct pkginfo *pkg) { l= strlen(pkg->set->name); if (l>20) maxl -= (l-20); - pdesc = pkg_summary(pkg, &l); + pdesc = pkg_summary(pkg, &pkg->installed, &l); l = min(l, maxl); printf(" %-20s %.*s\n", pkg->set->name, l, pdesc); diff --git a/src/querycmd.c b/src/querycmd.c index 94d56284a..1d169c6f7 100644 --- a/src/querycmd.c +++ b/src/querycmd.c @@ -4,7 +4,7 @@ * * Copyright © 1995,1996 Ian Jackson <ian@chiark.greenend.org.uk> * Copyright © 2000,2001 Wichert Akkerman <wakkerma@debian.org> - * Copyright © 2006-2011 Guillem Jover <guillem@debian.org> + * Copyright © 2006-2012 Guillem Jover <guillem@debian.org> * * This is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -105,7 +105,7 @@ list_format_init(struct list_format *fmt, struct pkg_array *array) plen = strlen(array->pkgs[i]->set->name); vlen = strlen(versiondescribe(&array->pkgs[i]->installed.version, vdew_nonambig)); - pkg_summary(array->pkgs[i], &dlen); + pkg_summary(array->pkgs[i], &array->pkgs[i]->installed, &dlen); if (plen > fmt->nw) fmt->nw = plen; @@ -183,7 +183,7 @@ list1package(struct pkginfo *pkg, struct list_format *fmt, struct pkg_array *arr list_format_init(fmt, array); list_format_print_header(fmt); - pdesc = pkg_summary(pkg, &l); + pdesc = pkg_summary(pkg, &pkg->installed, &l); l = min(l, fmt->dw); printf(fmt->format, |