diff options
author | Steve McIntyre <steve@einval.com> | 2021-03-23 23:49:46 +0000 |
---|---|---|
committer | Steve McIntyre <steve@einval.com> | 2021-03-23 23:49:46 +0000 |
commit | 1251a7ba86fc40a6aad8b4fecdbca2b61808d9fa (patch) | |
tree | 2125fda549aaca55cb49a48d54be77dec7fbf3df /errlog.c | |
parent | 85b409232ce89b34626df9d72abedf5d4f5ccef6 (diff) | |
parent | 031e5cce385d3f96b1caa1d53495332a7eb03749 (diff) | |
download | efi-boot-shim-debian/15.3-1.tar.gz efi-boot-shim-debian/15.3-1.zip |
Update upstream source from tag 'upstream/15.3'debian/15.3-1
Update to upstream version '15.3'
with Debian dir 1b484f1c1ac270604a5a1451b34de4b0865c6211
Diffstat (limited to 'errlog.c')
-rw-r--r-- | errlog.c | 31 |
1 files changed, 16 insertions, 15 deletions
@@ -5,30 +5,31 @@ */ #include "shim.h" -#include "hexdump.h" static CHAR16 **errs = NULL; static UINTN nerrs = 0; -EFI_STATUS -vdprint_(const CHAR16 *fmt, const char *file, int line, const char *func, va_list args) +EFI_STATUS EFIAPI +vdprint_(const CHAR16 *fmt, const char *file, int line, const char *func, + ms_va_list args) { - va_list args2; + ms_va_list args2; EFI_STATUS efi_status = EFI_SUCCESS; if (verbose) { - va_copy(args2, args); + ms_va_copy(args2, args); console_print(L"%a:%d:%a() ", file, line, func); efi_status = VPrint(fmt, args2); - va_end(args2); + ms_va_end(args2); } return efi_status; } -EFI_STATUS -VLogError(const char *file, int line, const char *func, const CHAR16 *fmt, va_list args) +EFI_STATUS EFIAPI +VLogError(const char *file, int line, const char *func, const CHAR16 *fmt, + ms_va_list args) { - va_list args2; + ms_va_list args2; CHAR16 **newerrs; newerrs = ReallocatePool(errs, (nerrs + 1) * sizeof(*errs), @@ -39,11 +40,11 @@ VLogError(const char *file, int line, const char *func, const CHAR16 *fmt, va_li newerrs[nerrs] = PoolPrint(L"%a:%d %a() ", file, line, func); if (!newerrs[nerrs]) return EFI_OUT_OF_RESOURCES; - va_copy(args2, args); + ms_va_copy(args2, args); newerrs[nerrs+1] = VPoolPrint(fmt, args2); if (!newerrs[nerrs+1]) return EFI_OUT_OF_RESOURCES; - va_end(args2); + ms_va_end(args2); nerrs += 2; newerrs[nerrs] = NULL; @@ -52,15 +53,15 @@ VLogError(const char *file, int line, const char *func, const CHAR16 *fmt, va_li return EFI_SUCCESS; } -EFI_STATUS +EFI_STATUS EFIAPI LogError_(const char *file, int line, const char *func, const CHAR16 *fmt, ...) { - va_list args; + ms_va_list args; EFI_STATUS efi_status; - va_start(args, fmt); + ms_va_start(args, fmt); efi_status = VLogError(file, line, func, fmt, args); - va_end(args); + ms_va_end(args); return efi_status; } |