diff options
-rw-r--r-- | src/ustar.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/ustar.c b/src/ustar.c index a77dace..21d41eb 100644 --- a/src/ustar.c +++ b/src/ustar.c @@ -146,16 +146,16 @@ opkg_opk_ustar_seek(struct opkg_opk_ustar *ustar, const char *member) name[sizeof(header.name)] = '\0'; } + if (strcmp((char *) name, member) == 0) { + return OPKG_OPK_OK; /* Member found */ + } + while (ustar->data_size_remaining > 0) { if (opkg_opk_ustar_read(ustar, NULL, NULL) == OPKG_OPK_ERROR) { return OPKG_OPK_ERROR; } } - - if (strcmp((char *) name, member) == 0) { - return OPKG_OPK_OK; /* Member found */ - } } return OPKG_OPK_ERROR; /* Member not found */ |