mirror of
https://github.com/acidanthera/audk.git
synced 2025-04-08 17:05:09 +02:00
This patch fixes the following Ecc reported error: There should be no initialization of a variable as part of its declaration Signed-off-by: Pierre Gondois <Pierre.Gondois@arm.com> Reviewed-by: Ard Biesheuvel <ard.biesheuvel@arm.com>
33 lines
758 B
C
33 lines
758 B
C
//------------------------------------------------------------------------------
|
|
//
|
|
// Copyright (c) 2017, Pete Batard. All rights reserved.<BR>
|
|
// Copyright (c) 2021, Arm Limited. All rights reserved.<BR>
|
|
//
|
|
// SPDX-License-Identifier: BSD-2-Clause-Patent
|
|
//
|
|
//------------------------------------------------------------------------------
|
|
|
|
#if defined(_M_ARM64)
|
|
typedef unsigned __int64 size_t;
|
|
#else
|
|
typedef unsigned __int32 size_t;
|
|
#endif
|
|
|
|
void* memcpy(void *, const void *, size_t);
|
|
#pragma intrinsic(memcpy)
|
|
#pragma function(memcpy)
|
|
void* memcpy(void *dest, const void *src, size_t n)
|
|
{
|
|
unsigned char *d;
|
|
unsigned char const *s;
|
|
|
|
d = dest;
|
|
s = src;
|
|
|
|
while (n-- != 0) {
|
|
*d++ = *s++;
|
|
}
|
|
|
|
return dest;
|
|
}
|