Date: Fri, 13 Mar 2026 09:14:19 +0000 From: Brooks Davis <brooks@FreeBSD.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org Cc: Juhyung Park <qkrwngud825@gmail.com> Subject: git: 3abef030d31a - stable/15 - Set errno to ENOMEM on rallocx() OOM failures Message-ID: <69b3d56b.3e47a.5e9a8fcf@gitrepo.freebsd.org>
index | next in thread | raw e-mail
The branch stable/15 has been updated by brooks: URL: https://cgit.FreeBSD.org/src/commit/?id=3abef030d31a9837ac7ba45bd8ee17340fabd120 commit 3abef030d31a9837ac7ba45bd8ee17340fabd120 Author: Juhyung Park <qkrwngud825@gmail.com> AuthorDate: 2026-03-03 09:59:33 +0000 Commit: Brooks Davis <brooks@FreeBSD.org> CommitDate: 2026-03-13 09:13:08 +0000 Set errno to ENOMEM on rallocx() OOM failures realloc() and rallocx() shares path, and realloc() should set errno to ENOMEM upon OOM failures. PR: 291677 Obtained from: jemalloc (commit 38056fea64c34ca4fef0a16212776eaa4de80b78) Fixes: c43cad871720 ("jemalloc: Merge from jemalloc 5.3.0 vendor branch") MFC after: 3 days Pull Request: https://github.com/freebsd/freebsd-src/pull/2059 (cherry picked from commit 5583b64f230fe0ea4e3d4bf4566205b521190fbb) --- contrib/jemalloc/src/jemalloc.c | 1 + 1 file changed, 1 insertion(+) diff --git a/contrib/jemalloc/src/jemalloc.c b/contrib/jemalloc/src/jemalloc.c index e4b183d1a24d..352c18870e0b 100644 --- a/contrib/jemalloc/src/jemalloc.c +++ b/contrib/jemalloc/src/jemalloc.c @@ -3561,6 +3561,7 @@ do_rallocx(void *ptr, size_t size, int flags, bool is_realloc) { return p; label_oom: + set_errno(ENOMEM); if (config_xmalloc && unlikely(opt_xmalloc)) { malloc_write("<jemalloc>: Error in rallocx(): out of memory\n"); abort();home | help
Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?69b3d56b.3e47a.5e9a8fcf>
