mirror of https://github.com/acidanthera/audk.git
0bcc503595
The immediately preceding call, GetBestLanguage, plus the implementation of HiiGetString, which is called immediately afterwards, make it clear that BestLanguage is a null-terminated ASCII string, and not just a five byte, non-null terminated buffer. Therefore AsciiStrLen is one byte too short, meaning that whether the space allocated is really sufficient and whether the resultant string is really null-terminated becomes implementation-dependent. Rather than switching to AsciiStrSize, we use an explicitly compile-time string length calculation (both compile-time and run-time approaches are currently used elsewhere in the codebase for copying static strings). Signed-off-by: Mike Beaton <mjsbeaton@gmail.com> Reviewed-by: Liming Gao <gaoliming@byosoft.com.cn> Reviewed-by: Dandan Bi <dandan.bi@intel.com> |
||
---|---|---|
.. | ||
ConfigKeywordHandler.c | ||
ConfigRouting.c | ||
Database.c | ||
Font.c | ||
HiiDatabase.h | ||
HiiDatabase.uni | ||
HiiDatabaseDxe.inf | ||
HiiDatabaseEntry.c | ||
HiiDatabaseExtra.uni | ||
Image.c | ||
ImageEx.c | ||
String.c |