aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/package.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/package.c b/src/package.c
index 9e74854d0f..ee3f40e94a 100644
--- a/src/package.c
+++ b/src/package.c
@@ -275,7 +275,7 @@ void apk_deps_parse(struct apk_database *db,
{
struct parse_depend_ctx ctx = { db, depends };
- if (blob.len > 1 && blob.ptr[blob.len-1] == '\n')
+ if (blob.len > 0 && blob.ptr[blob.len-1] == '\n')
blob.len--;
apk_blob_for_each_segment(blob, " ", parse_depend, &ctx);