Bug 784739 - Switch from NULL to nullptr in toolkit/components/ (2/2); r=ehsan
This commit is contained in:
@@ -63,8 +63,8 @@ Base64urlEncode(const uint8_t* aBytes,
|
||||
uint32_t aNumBytes,
|
||||
nsCString& _result)
|
||||
{
|
||||
// SetLength does not set aside space for NULL termination. PL_Base64Encode
|
||||
// will not NULL terminate, however, nsCStrings must be NULL terminated. As a
|
||||
// SetLength does not set aside space for null termination. PL_Base64Encode
|
||||
// will not null terminate, however, nsCStrings must be null terminated. As a
|
||||
// result, we set the capacity to be one greater than what we need, and the
|
||||
// length to our desired length.
|
||||
uint32_t length = (aNumBytes + 2) / 3 * 4; // +2 due to integer math.
|
||||
|
||||
Reference in New Issue
Block a user