mirror of
https://github.com/godotengine/godot.git
synced 2025-12-08 06:09:55 +00:00
Remove String clipping constructors.
Callers should instead call constructors with explicit encoding names, with known length `Span`.
This commit is contained in:
parent
b377562b52
commit
a23f630781
12 changed files with 24 additions and 41 deletions
|
|
@ -806,7 +806,8 @@ String OS_MacOS::get_system_ca_certificates() {
|
|||
Error err = CryptoCore::b64_encode(pba.ptrw(), pba.size(), &b64len, (unsigned char *)CFDataGetBytePtr(der), derlen);
|
||||
CFRelease(der);
|
||||
ERR_CONTINUE(err != OK);
|
||||
certs += "-----BEGIN CERTIFICATE-----\n" + String((char *)pba.ptr(), b64len) + "\n-----END CERTIFICATE-----\n";
|
||||
// Certificate is bas64 encoded, aka ascii.
|
||||
certs += "-----BEGIN CERTIFICATE-----\n" + String::ascii(Span((char *)pba.ptr(), b64len)) + "\n-----END CERTIFICATE-----\n";
|
||||
}
|
||||
CFRelease(result);
|
||||
return certs;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue