From b44ae0026bd761edb3e4dee17905bf2d96e27355 Mon Sep 17 00:00:00 2001 From: kettenis Date: Sun, 16 Apr 2017 13:35:14 +0000 Subject: [PATCH] Always return nonzero from _longjmp too. ok jsg@ --- lib/libc/arch/aarch64/gen/_setjmp.S | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/libc/arch/aarch64/gen/_setjmp.S b/lib/libc/arch/aarch64/gen/_setjmp.S index 220ef839a97..29f7196a716 100644 --- a/lib/libc/arch/aarch64/gen/_setjmp.S +++ b/lib/libc/arch/aarch64/gen/_setjmp.S @@ -1,4 +1,4 @@ -/* $OpenBSD: _setjmp.S,v 1.1 2017/01/11 18:09:24 patrick Exp $ */ +/* $OpenBSD: _setjmp.S,v 1.2 2017/04/16 13:35:14 kettenis Exp $ */ /*- * Copyright (c) 2014 Andrew Turner * Copyright (c) 2014 The FreeBSD Foundation @@ -91,7 +91,8 @@ ENTRY(_longjmp) #endif /* Load the return value */ - mov x0, x1 + cmp w1, #0 + csinc w0, w1, wzr, ne ret botch: -- 2.20.1