diff options
Diffstat (limited to 'meta/recipes-extended/zip/zip-3.0/0001-fileio.c-fix-a-buffer-overflow-detected-issue.patch')
| -rw-r--r-- | meta/recipes-extended/zip/zip-3.0/0001-fileio.c-fix-a-buffer-overflow-detected-issue.patch | 38 |
1 files changed, 0 insertions, 38 deletions
diff --git a/meta/recipes-extended/zip/zip-3.0/0001-fileio.c-fix-a-buffer-overflow-detected-issue.patch b/meta/recipes-extended/zip/zip-3.0/0001-fileio.c-fix-a-buffer-overflow-detected-issue.patch deleted file mode 100644 index d760dfcec5..0000000000 --- a/meta/recipes-extended/zip/zip-3.0/0001-fileio.c-fix-a-buffer-overflow-detected-issue.patch +++ /dev/null | |||
| @@ -1,38 +0,0 @@ | |||
| 1 | From 23b4ed82bff20c737fe2e95d5b035e92a9522ca2 Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Ming Liu <liu.ming50@gmail.com> | ||
| 3 | Date: Thu, 15 May 2025 13:58:45 +0200 | ||
| 4 | Subject: [PATCH] fileio.c: fix a buffer overflow detected issue | ||
| 5 | MIME-Version: 1.0 | ||
| 6 | Content-Type: text/plain; charset=UTF-8 | ||
| 7 | Content-Transfer-Encoding: 8bit | ||
| 8 | |||
| 9 | Fix a following issue: | ||
| 10 | | *** buffer overflow detected ***: terminated | ||
| 11 | | | ||
| 12 | | zip error: Interrupted (aborting) | ||
| 13 | |||
| 14 | Reference: https://bugzilla.redhat.com/show_bug.cgi?id=2165653 | ||
| 15 | |||
| 16 | Upstream-Status: Inactive-Upstream [the fix is from Redhat but not the official project] | ||
| 17 | |||
| 18 | Signed-off-by: Ming Liu <liu.ming50@gmail.com> | ||
| 19 | --- | ||
| 20 | fileio.c | 2 +- | ||
| 21 | 1 file changed, 1 insertion(+), 1 deletion(-) | ||
| 22 | |||
| 23 | diff --git a/fileio.c b/fileio.c | ||
| 24 | index 1847e62..5a2959d 100644 | ||
| 25 | --- a/fileio.c | ||
| 26 | +++ b/fileio.c | ||
| 27 | @@ -3502,7 +3502,7 @@ zwchar *local_to_wide_string(local_string) | ||
| 28 | if ((wc_string = (wchar_t *)malloc((wsize + 1) * sizeof(wchar_t))) == NULL) { | ||
| 29 | ZIPERR(ZE_MEM, "local_to_wide_string"); | ||
| 30 | } | ||
| 31 | - wsize = mbstowcs(wc_string, local_string, strlen(local_string) + 1); | ||
| 32 | + wsize = mbstowcs(wc_string, local_string, wsize + 1); | ||
| 33 | wc_string[wsize] = (wchar_t) 0; | ||
| 34 | |||
| 35 | /* in case wchar_t is not zwchar */ | ||
| 36 | -- | ||
| 37 | 2.43.0 | ||
| 38 | |||
