代码拉取完成,页面将自动刷新
From 2572bd2553df79d326af01c3536eeb523f962fe6 Mon Sep 17 00:00:00 2001
From: Florian Weimer <fweimer@redhat.com>
Date: Tue, 19 Dec 2023 11:00:11 +0100
Subject: [PATCH] configure: Only test the makecontext signature we need
The test/explicit-bzero.c test uses a start routine without any
arguments. There is no need for the multi-argument version.
This avoids a build failure with glibc and future compilers.
The GNU C library declares the makecontext callback of
type void (*) (void), so no cast is needed. On other systems,
the type may be the (currently distinct) type void (*) (),
but given that this only affects the ability to execute a test,
no further machinery is added here to detect that different type.
---
configure.ac | 2 --
1 file changed, 2 deletions(-)
diff --git a/configure.ac b/configure.ac
index 016997c8..4b8afd89 100644
--- a/configure.ac
+++ b/configure.ac
@@ -303,13 +303,11 @@ AS_IF([test $ac_cv_header_ucontext_h = yes],
#include <ucontext.h>
static int x;
static void fn1(void) {}
-static void fn2(int a, int b) { x = a - b; }
]], [[
ucontext_t uc1, uc2;
if (getcontext(&uc1)) return 1;
if (setcontext(&uc1)) return 1;
makecontext(&uc1, fn1, 0);
- makecontext(&uc2, fn2, 2, 1, 1);
if (swapcontext(&uc1, &uc2)) return 1;
return x;
]])],
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。