diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-08-07 13:30:08 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-08-07 13:30:08 +0000 |
commit | 44cf9c6d2d274eac37502e835155f7e985f1b8e6 (patch) | |
tree | 9576ba968924c5b9a55ba9e14f4f26184c62c7d4 /src/main/select.c | |
parent | Adding upstream version 1.22.6. (diff) | |
download | dpkg-44cf9c6d2d274eac37502e835155f7e985f1b8e6.tar.xz dpkg-44cf9c6d2d274eac37502e835155f7e985f1b8e6.zip |
Adding upstream version 1.22.7.upstream/1.22.7
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'src/main/select.c')
-rw-r--r-- | src/main/select.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/main/select.c b/src/main/select.c index d71202e..6e81d97 100644 --- a/src/main/select.c +++ b/src/main/select.c @@ -156,7 +156,6 @@ setselections(const char *const *argv) ohshit(_("unexpected end of file in package name at line %d"), lno); if (c == '\n') ohshit(_("unexpected end of line in package name at line %d"),lno); } - varbuf_end_str(&namevb); while (c != EOF && c_isspace(c)) { c= getchar(); @@ -170,28 +169,29 @@ setselections(const char *const *argv) varbuf_add_char(&selvb, c); c= getchar(); } - varbuf_end_str(&selvb); while (c != EOF && c != '\n') { c= getchar(); if (!c_isspace(c)) ohshit(_("unexpected data after package and selection at line %d"),lno); } - pkg = pkg_spec_parse_pkg(namevb.buf, &err); + pkg = pkg_spec_parse_pkg(varbuf_str(&namevb), &err); if (pkg == NULL) ohshit(_("illegal package name at line %d: %.250s"), lno, err.str); if (!pkg_is_informative(pkg, &pkg->installed) && !pkg_is_informative(pkg, &pkg->available)) { db_possibly_outdated = true; - warning(_("package not in status nor available database at line %d: %.250s"), lno, namevb.buf); + warning(_("package not in status nor available database at line %d: %.250s"), + lno, varbuf_str(&namevb)); lno++; continue; } - nv = namevalue_find_by_name(wantinfos, selvb.buf); + nv = namevalue_find_by_name(wantinfos, varbuf_str(&selvb)); if (nv == NULL) - ohshit(_("unknown wanted status at line %d: %.250s"), lno, selvb.buf); + ohshit(_("unknown wanted status at line %d: %.250s"), + lno, varbuf_str(&selvb)); pkg_set_want(pkg, nv->value); if (c == EOF) break; |