Bug 1766561 - Adjust UTF-16 string formatting. r=nika
With MOZ_FORMAT_PRINTF annotations, the compiler expects a wchar_t*, and it won't automatically consider char16ptr_t to be compatible with that. While handling strings, there's one case of formatting that doesn't need to use %S at all. Differential Revision: https://phabricator.services.mozilla.com/D144919
This commit is contained in:
@@ -805,7 +805,7 @@ static nsresult CreateShortcutImpl(
|
||||
// TODO: Properly escape quotes in the string, see bug 1604287.
|
||||
nsString arguments;
|
||||
for (auto& arg : aArguments) {
|
||||
arguments.AppendPrintf("\"%S\" ", arg.get());
|
||||
arguments.AppendPrintf("\"%S\" ", static_cast<const wchar_t*>(arg.get()));
|
||||
}
|
||||
|
||||
link->SetArguments(arguments.get());
|
||||
|
||||
Reference in New Issue
Block a user