summaryrefslogtreecommitdiff
path: root/src/archive.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/archive.c')
-rw-r--r--src/archive.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/archive.c b/src/archive.c
index 26419d4..2cfb3e6 100644
--- a/src/archive.c
+++ b/src/archive.c
@@ -219,9 +219,10 @@ int apk_tar_parse(struct apk_istream *is, apk_archive_entry_parser parser,
/* Read remaining end-of-archive records, to ensure we read all of
* the file. The underlying istream is likely doing checksumming. */
if (r == 512) {
- while ((r = is->read(is, &buf, 512)) == 512)
+ while ((r = is->read(is, &buf, 512)) == 512) {
if (buf.name[0] != 0)
return -1;
+ }
}
/* Check that there was no partial record */