X-Git-Url: https://code.delx.au/refind/blobdiff_plain/315c06865c0b4e3dfceec2107e6e12713813ea8a..cc81100ca9d8e17fffcbffc85bd401fcbe445038:/filesystems/fsw_efi_lib.c diff --git a/filesystems/fsw_efi_lib.c b/filesystems/fsw_efi_lib.c index 93a7ff1..31f7c2f 100644 --- a/filesystems/fsw_efi_lib.c +++ b/filesystems/fsw_efi_lib.c @@ -1,23 +1,9 @@ -/* $Id: fsw_efi_lib.c 29125 2010-05-06 09:43:05Z vboxsync $ */ -/** @file - * fsw_efi_lib.c - EFI host environment library functions. - */ - -/* - * Copyright (C) 2010 Oracle Corporation - * - * This file is part of VirtualBox Open Source Edition (OSE), as - * available from http://www.virtualbox.org. This file is free software; - * you can redistribute it and/or modify it under the terms of the GNU - * General Public License (GPL) as published by the Free Software - * Foundation, in version 2 as it comes in the "COPYING" file of the - * VirtualBox OSE distribution. VirtualBox OSE is distributed in the - * hope that it will be useful, but WITHOUT ANY WARRANTY of any kind. +/** + * \file fsw_efi_lib.c + * EFI host environment library functions. */ /*- - * This code is based on: - * * Copyright (c) 2006 Christoph Pfisterer * * Redistribution and use in source and binary forms, with or without @@ -129,7 +115,7 @@ UINTN fsw_efi_strsize(struct fsw_string *s) VOID fsw_efi_strcpy(CHAR16 *Dest, struct fsw_string *src) { - if (src->type == FSW_STRING_TYPE_EMPTY) { + if (src->type == FSW_STRING_TYPE_EMPTY | src->size == 0) { Dest[0] = 0; } else if (src->type == FSW_STRING_TYPE_UTF16) { CopyMem(Dest, src->data, src->size); @@ -140,21 +126,4 @@ VOID fsw_efi_strcpy(CHAR16 *Dest, struct fsw_string *src) } } -int fsw_streq_ISO88591_UTF16(void *s1data, void *s2data, int len) -{ - int i; - fsw_u8 *p1 = (fsw_u8 *)s1data; - fsw_u16 *p2 = (fsw_u16 *)s2data; - - for (i = 0; i