blob: 2ae9a0d4559f14903497e1e74e7bc3c9ac24044f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
/** @file
The longjmp function.
The C standard requires that longjmp be a function and not a macro.
Copyright (c) 2011, Intel Corporation. All rights reserved.<BR>
This program and the accompanying materials are licensed and made available under
the terms and conditions of the BSD License that accompanies this distribution.
The full text of the license may be found at
http://opensource.org/licenses/bsd-license.
THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
**/
#include <Library/BaseLib.h>
#include <setjmp.h>
void longjmp(jmp_buf env, int val)
{
LongJump(env, (UINTN)((val == 0) ? 1 : val));
}
|