From e74b80da5031162e9f2fdc1d058326f2781a2a9e Mon Sep 17 00:00:00 2001 From: NishiOwO Date: Tue, 30 Sep 2025 15:06:13 +0000 Subject: [PATCH] fix git-svn-id: http://svn2.nishi.boats/svn/milsko/trunk@81 b9cfdab3-6d41-4d17-bbe4-086880011989 --- include/Mw/Core.h | 4 ++-- src/core.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/include/Mw/Core.h b/include/Mw/Core.h index 4b733fc..a2b4557 100644 --- a/include/Mw/Core.h +++ b/include/Mw/Core.h @@ -178,9 +178,9 @@ MWDECL void MwDispatchError(int code, const char* message); /*! * %brief Gets the before_step of widget * %param handle Widget - * %return jmp_buf + * %param jmpbuf jmp_buf */ -MWDECL jmp_buf MwGetBeforeStep(MwWidget handle); +MWDECL void MwGetBeforeStep(MwWidget handle, jmp_buf* jmpbuf); #ifdef __cplusplus } diff --git a/src/core.c b/src/core.c index a0ef5de..bffbb7a 100644 --- a/src/core.c +++ b/src/core.c @@ -275,6 +275,6 @@ void MwDispatchError(int code, const char* message) { } } -jmp_buf MwGetBeforeStep(MwWidget handle) { - return handle->before_step; +void MwGetBeforeStep(MwWidget handle, jmp_buf* jmpbuf) { + memcpy(jmpbuf, &handle->before_step, sizeof(*jmpbuf)); }