diff options
author | Gaspartcho <93390411+Gaspartcho@users.noreply.github.com> | 2024-02-25 23:23:28 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-02-25 17:23:28 -0500 |
commit | b4931cb618a2b4d22482694cbc40e60990d684fc (patch) | |
tree | 52abca3095dda3a78f295a997d76d2ab0aadfbc3 /lib/microtar | |
parent | 59a4f6f5018a77f12528dd5d21dd7627b39a54a8 (diff) | |
download | lite-xl-plugin-manager-b4931cb618a2b4d22482694cbc40e60990d684fc.tar.gz lite-xl-plugin-manager-b4931cb618a2b4d22482694cbc40e60990d684fc.zip |
hopefully fixed the memory leak (#83)
Diffstat (limited to 'lib/microtar')
-rw-r--r-- | lib/microtar/src/microtar.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/microtar/src/microtar.c b/lib/microtar/src/microtar.c index 1cd9920..20c509d 100644 --- a/lib/microtar/src/microtar.c +++ b/lib/microtar/src/microtar.c @@ -337,8 +337,9 @@ int mtar_clear_header(mtar_header_t *h){ h->size = 0; h->mtime = 0; h->type = 0; - bzero(h->name, strlen(h->name)); - bzero(h->linkname, strlen(h->linkname)); + + bzero(h->name, sizeof(h->name)); + bzero(h->linkname, sizeof(h->linkname)); return MTAR_ESUCCESS; } |