GCC Code Coverage Report
Directory: ./ Exec Total Coverage
File: fx_unicode_name_get.c Lines: 2 2 100.0 %
Date: 2024-03-11 05:15:45 Branches: 0 0 - %

Line Branch Exec Source
1
/***************************************************************************
2
 * Copyright (c) 2024 Microsoft Corporation
3
 *
4
 * This program and the accompanying materials are made available under the
5
 * terms of the MIT License which is available at
6
 * https://opensource.org/licenses/MIT.
7
 *
8
 * SPDX-License-Identifier: MIT
9
 **************************************************************************/
10
11
12
/**************************************************************************/
13
/**************************************************************************/
14
/**                                                                       */
15
/** FileX Component                                                       */
16
/**                                                                       */
17
/**   Unicode                                                             */
18
/**                                                                       */
19
/**************************************************************************/
20
/**************************************************************************/
21
22
#define FX_SOURCE_CODE
23
24
25
/* Include necessary system files.  */
26
27
#include "fx_api.h"
28
#include "fx_unicode.h"
29
30
31
/**************************************************************************/
32
/*                                                                        */
33
/*  FUNCTION                                               RELEASE        */
34
/*                                                                        */
35
/*    _fx_unicode_name_get                                PORTABLE C      */
36
/*                                                           6.1          */
37
/*  AUTHOR                                                                */
38
/*                                                                        */
39
/*    William E. Lamie, Microsoft Corporation                             */
40
/*                                                                        */
41
/*  DESCRIPTION                                                           */
42
/*                                                                        */
43
/*    This function finds the unicode name associated with the supplied   */
44
/*    short 8.3 name.                                                     */
45
/*                                                                        */
46
/*    Note, this API is deprecated as fx_unicode_name_get_extended should */
47
/*    be used. The maximum written size to destination_unicode_name could */
48
/*    be FX_MAX_LONG_NAME_LEN * 2.                                        */
49
/*                                                                        */
50
/*  INPUT                                                                 */
51
/*                                                                        */
52
/*    media_ptr                             Pointer to media              */
53
/*    source_short_name                     Pointer to short file name    */
54
/*    destination_unicode_name              Pointer to destination name   */
55
/*    destination_unicode_length            Destination for name length   */
56
/*                                                                        */
57
/*  OUTPUT                                                                */
58
/*                                                                        */
59
/*    Completion Status                                                   */
60
/*                                                                        */
61
/*  CALLS                                                                 */
62
/*                                                                        */
63
/*    _fx_unicode_name_get_extended         Actual unicode name get       */
64
/*                                            service                     */
65
/*                                                                        */
66
/*  CALLED BY                                                             */
67
/*                                                                        */
68
/*    Application Code                                                    */
69
/*                                                                        */
70
/*  RELEASE HISTORY                                                       */
71
/*                                                                        */
72
/*    DATE              NAME                      DESCRIPTION             */
73
/*                                                                        */
74
/*  05-19-2020     William E. Lamie         Initial Version 6.0           */
75
/*  09-30-2020     William E. Lamie         Modified comment(s),          */
76
/*                                            resulting in version 6.1    */
77
/*                                                                        */
78
/**************************************************************************/
79
12
UINT  _fx_unicode_name_get(FX_MEDIA *media_ptr, CHAR *source_short_name,
80
                           UCHAR *destination_unicode_name, ULONG *destination_unicode_length)
81
{
82
83
    /* Call the extended version with 13 bytes short name length.  */
84
12
    return(_fx_unicode_name_get_extended(media_ptr, source_short_name, destination_unicode_name, destination_unicode_length, FX_MAX_LONG_NAME_LEN * 2));
85
}
86