mirror of
https://github.com/servo/servo.git
synced 2025-08-05 05:30:08 +01:00
Fixed usage of wrong delete
This commit is contained in:
parent
582a7a7afa
commit
4282f3b0a9
1 changed files with 1 additions and 1 deletions
|
@ -13,7 +13,7 @@ std::wstring format(const std::wstring &txt, Args... args) {
|
||||||
auto ptr = new wchar_t[size];
|
auto ptr = new wchar_t[size];
|
||||||
swprintf(ptr, size, txt.c_str(), args...);
|
swprintf(ptr, size, txt.c_str(), args...);
|
||||||
auto wstr = std::wstring(ptr);
|
auto wstr = std::wstring(ptr);
|
||||||
delete ptr;
|
delete[] ptr;
|
||||||
return wstr;
|
return wstr;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue