Commit 812a6a31 authored by Timo Teräs's avatar Timo Teräs
Browse files

ver: fix output indentation

parent dc5c436c
...@@ -78,6 +78,7 @@ static void ver_print_package_status(struct apk_package *pkg) ...@@ -78,6 +78,7 @@ static void ver_print_package_status(struct apk_package *pkg)
{ {
struct apk_name *name; struct apk_name *name;
struct apk_package *latest, *tmp; struct apk_package *latest, *tmp;
char pkgname[256];
int i, r; int i, r;
name = pkg->name; name = pkg->name;
...@@ -92,7 +93,8 @@ static void ver_print_package_status(struct apk_package *pkg) ...@@ -92,7 +93,8 @@ static void ver_print_package_status(struct apk_package *pkg)
latest = tmp; latest = tmp;
} }
r = apk_pkg_version_compare(pkg, latest); r = apk_pkg_version_compare(pkg, latest);
printf("%s-%-40s%s %s\n", name->name, pkg->version, apk_version_op_string(r), latest->version); snprintf(pkgname, sizeof(pkgname), "%s-%s", name->name, pkg->version);
printf("%-40s%s %s\n", pkgname, apk_version_op_string(r), latest->version);
} }
static int ver_main(void *ctx, int argc, char **argv) static int ver_main(void *ctx, int argc, char **argv)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment