HomePhabricator

Clear the output string passed to GetHostName()

Authored by asmith on Apr 16 2019, 8:13 PM.

Description

Clear the output string passed to GetHostName()

LLVM's wchar to UTF8 conversion routine expects an empty string to store the output.
GetHostName() on Windows is sometimes called with a non-empty string which triggers
an assert. The simple fix is to clear the output string before the conversion.

llvm-svn: 358550

Details

Committed
asmithApr 16 2019, 8:13 PM
Parents
rG990514cec829: clangd: Change Windows.h to windows.h.
Branches
Unknown
Tags
Unknown