diff options
-rw-r--r-- | libopkg/pkg.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/libopkg/pkg.c b/libopkg/pkg.c index c5a3336..467dcef 100644 --- a/libopkg/pkg.c +++ b/libopkg/pkg.c @@ -309,8 +309,13 @@ pkg_init_from_file(pkg_t *pkg, const char *filename) rewind(control_file); - if (pkg_parse_from_stream(pkg, control_file, 0)) + if ((err = pkg_parse_from_stream(pkg, control_file, 0))) { + if (err == 1) { + opkg_msg(ERROR, "Malformed package file %s.\n", + filename); + } err = -1; + } err2: fclose(control_file); |