Projects
openEuler:24.03:SP1:Everything
elfutils
_service:tar_scm:Fix-segfault-in-eu-ar-m.patch
Sign Up
Log In
Username
Password
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File _service:tar_scm:Fix-segfault-in-eu-ar-m.patch of Package elfutils
From 68d0321a35c4bf3ccd8c8a74747739658f02e01a Mon Sep 17 00:00:00 2001 From: xiezhipeng <xiezhipeng1@huawei.com> Date: Wed, 8 Dec 2021 09:47:36 +0800 Subject: [PATCH] fix segfault in eu-ar -m Fix segfaultineu-ar-m. --- src/ar.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/ar.c b/src/ar.c index 3bcb18f..072ca2e 100644 --- a/src/ar.c +++ b/src/ar.c @@ -1155,6 +1155,7 @@ do_oper_insert (int oper, const char *arfname, char **argv, int argc, goto next; struct armem *newp = alloca (sizeof (struct armem)); + memset (newp, '\0', sizeof(struct armem)); newp->old_off = elf_getaroff (subelf); newp->size = arhdr->ar_size; newp->sec = arhdr->ar_date; @@ -1247,6 +1248,7 @@ do_oper_insert (int oper, const char *arfname, char **argv, int argc, if (found[cnt] == NULL) { found[cnt] = alloca (sizeof (struct armem)); + memset (found[cnt], '\0', sizeof(struct armem)); found[cnt]->old_off = -1; remember_long_name (found[cnt], bname, bnamelen); -- 2.27.0
Locations
Projects
Search
Status Monitor
Help
Open Build Service
OBS Manuals
API Documentation
OBS Portal
Reporting a Bug
Contact
Mailing List
Forums
Chat (IRC)
Twitter
Open Build Service (OBS)
is an
openSUSE project
.
浙ICP备2022010568号-2