diff options
author | Adam Harrison <adamdharrison@gmail.com> | 2024-10-14 13:02:39 -0400 |
---|---|---|
committer | Adam Harrison <adamdharrison@gmail.com> | 2024-10-14 13:02:39 -0400 |
commit | 13d213a3a254ff93346092b3eab0d819a394db3f (patch) | |
tree | 7c73dcf82a61b2b0b607de9b19e19e3983fe8b5b /lib | |
parent | 526c21d62b0688b6b5128cda72c35e4fcc996d91 (diff) | |
download | lite-xl-plugin-manager-13d213a3a254ff93346092b3eab0d819a394db3f.tar.gz lite-xl-plugin-manager-13d213a3a254ff93346092b3eab0d819a394db3f.zip |
Small changes to microtar, fixed some issues with the long names in the extract code.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/microtar/src/microtar.c | 10 | ||||
-rw-r--r-- | lib/microtar/src/microtar.h | 23 |
2 files changed, 13 insertions, 20 deletions
diff --git a/lib/microtar/src/microtar.c b/lib/microtar/src/microtar.c index 6130a49..2757116 100644 --- a/lib/microtar/src/microtar.c +++ b/lib/microtar/src/microtar.c @@ -332,15 +332,7 @@ int mtar_update_header(mtar_header_t *h, mtar_header_t *oh) { int mtar_clear_header(mtar_header_t *h){ - h->mode = 0; - h->owner = 0; - h->size = 0; - h->mtime = 0; - h->type = 0; - - memset(h->name, 0, sizeof(h->name)); - memset(h->linkname, 0, sizeof(h->linkname)); - + memset(h, 0, sizeof(mtar_header_t)); return MTAR_ESUCCESS; } diff --git a/lib/microtar/src/microtar.h b/lib/microtar/src/microtar.h index 1b3c09d..8298ee4 100644 --- a/lib/microtar/src/microtar.h +++ b/lib/microtar/src/microtar.h @@ -33,17 +33,18 @@ enum { }; enum { - MTAR_TREG = '0', - MTAR_TLNK = '1', - MTAR_TSYM = '2', - MTAR_TCHR = '3', - MTAR_TBLK = '4', - MTAR_TDIR = '5', - MTAR_TFIFO = '6', - MTAR_TEHR = 'x', // PAX file format - MTAR_TEHRA = 'g', // PAX file format - MTAR_TGFP = 'K', // GNU file format - MTAR_TGLP = 'L' // GNU file format + MTAR_TREG = '0', + MTAR_TLNK = '1', + MTAR_TSYM = '2', + MTAR_TCHR = '3', + MTAR_TBLK = '4', + MTAR_TDIR = '5', + MTAR_TFIFO = '6', + MTAR_TCON = '7', + MTAR_TEHR = 'x', // PAX file format + MTAR_TEHRA = 'g', // PAX file format + MTAR_TGLP = 'K', // GNU file format + MTAR_TGFP = 'L' // GNU file format }; typedef struct { |