mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 784739 - Switch from NULL to nullptr in security/; r=ehsan
This commit is contained in:
parent
ca89c214af
commit
5d748e0ca5
@ -236,7 +236,7 @@ class ScopedAutoSECItem MOZ_FINAL : public SECItem
|
||||
public:
|
||||
ScopedAutoSECItem(uint32_t initialAllocatedLen = 0)
|
||||
{
|
||||
data = NULL;
|
||||
data = nullptr;
|
||||
len = 0;
|
||||
if (initialAllocatedLen > 0) {
|
||||
SECITEM_AllocItem(*this, initialAllocatedLen);
|
||||
|
@ -2307,8 +2307,8 @@ nsCrypto::ImportUserCertificates(const nsAString& aNickname,
|
||||
//certificates. Let's keep an array of them around which
|
||||
//we pass along to the nsP12Runnable to use.
|
||||
certArr = new nsIX509Cert*[numResponses];
|
||||
// If this is NULL, chances are we're gonna fail really soon,
|
||||
// but let's try to keep going just in case.
|
||||
// If this is nullptr, chances are we're gonna fail really
|
||||
// soon, but let's try to keep going just in case.
|
||||
if (!certArr)
|
||||
aDoForcedBackup = false;
|
||||
|
||||
|
@ -88,7 +88,7 @@ struct nsMyTrustedEVInfo
|
||||
* Remove all whitespaces. If you use multiple lines, make sure that
|
||||
* only the final line will be followed by a comma.
|
||||
* - the "Serial DER Base64" (as printed by pp)
|
||||
* - a NULL pointer value
|
||||
* - a nullptr value
|
||||
*
|
||||
* After adding an entry, test it locally against the test site that
|
||||
* has been provided by the CA. Note that you must use a version of NSS
|
||||
|
@ -942,8 +942,8 @@ ProcessName(CERTName *name, nsINSSComponent *nssComponent, PRUnichar **value)
|
||||
lastRdn = rdns;
|
||||
while (*lastRdn) lastRdn++;
|
||||
// The above whille loop will put us at the last member
|
||||
// of the array which is a NULL pointer. So let's back
|
||||
// up one spot so that we have the last non-NULL entry in
|
||||
// of the array which is a nullptr pointer. So let's back
|
||||
// up one spot so that we have the last non-nullptr entry in
|
||||
// the array in preparation for traversing the
|
||||
// RDN's (Relative Distinguished Name) in reverse oder.
|
||||
lastRdn--;
|
||||
|
@ -2024,9 +2024,9 @@ private:
|
||||
* - socket: SSL socket we're dealing with
|
||||
* - caNames: list of CA names
|
||||
* - pRetCert: returns a pointer to a pointer to a valid certificate if
|
||||
* successful; otherwise NULL
|
||||
* successful; otherwise nullptr
|
||||
* - pRetKey: returns a pointer to a pointer to the corresponding key if
|
||||
* successful; otherwise NULL
|
||||
* successful; otherwise nullptr
|
||||
* - returns: SECSuccess if successful; error code otherwise
|
||||
*/
|
||||
SECStatus nsNSS_SSLGetClientAuthData(void* arg, PRFileDesc* socket,
|
||||
|
@ -64,7 +64,7 @@ private:
|
||||
// - When the user entered a zero length password.
|
||||
// An empty password should be represented as an empty
|
||||
// string (a SECItem that contains a single terminating
|
||||
// NULL UTF16 character), but some applications use a
|
||||
// null UTF16 character), but some applications use a
|
||||
// zero length SECItem.
|
||||
// We try both variations, zero length item and empty string,
|
||||
// without giving a user prompt when trying the different empty password flavors.
|
||||
|
@ -30,7 +30,7 @@ nsRandomGenerator::GenerateRandomBytes(uint32_t aLength,
|
||||
return NS_ERROR_OUT_OF_MEMORY;
|
||||
|
||||
mozilla::ScopedPK11SlotInfo slot(PK11_GetInternalSlot());
|
||||
if (slot == NULL) {
|
||||
if (slot == nullptr) {
|
||||
return NS_ERROR_FAILURE;
|
||||
}
|
||||
SECStatus srv = PK11_GenerateRandomOnSlot(slot, buf, aLength);
|
||||
|
@ -11,6 +11,7 @@
|
||||
#include <signal.h>
|
||||
#include <string.h>
|
||||
|
||||
#include "mozilla/NullPtr.h"
|
||||
#include "mozilla/Util.h"
|
||||
#if defined(ANDROID)
|
||||
#include "android_ucontext.h"
|
||||
@ -109,12 +110,12 @@ InstallSyscallReporter(void)
|
||||
|
||||
act.sa_sigaction = &Reporter;
|
||||
act.sa_flags = SA_SIGINFO | SA_NODEFER;
|
||||
if (sigaction(SIGSYS, &act, NULL) < 0) {
|
||||
if (sigaction(SIGSYS, &act, nullptr) < 0) {
|
||||
return -1;
|
||||
}
|
||||
if (sigemptyset(&mask) ||
|
||||
sigaddset(&mask, SIGSYS) ||
|
||||
sigprocmask(SIG_UNBLOCK, &mask, NULL)) {
|
||||
sigprocmask(SIG_UNBLOCK, &mask, nullptr)) {
|
||||
return -1;
|
||||
}
|
||||
return 0;
|
||||
|
Loading…
Reference in New Issue
Block a user