Backed out changeset 5184f19384c8 (bug 1049434)

This commit is contained in:
Tim Taubert 2014-08-07 09:21:13 +02:00
parent 15405e9b5b
commit 88a6354eac
2 changed files with 2 additions and 6 deletions

View File

@ -150,7 +150,7 @@ CryptoBuffer::ToSECItem() const
return nullptr;
}
SECItem* item = ::SECITEM_AllocItem(nullptr, nullptr, 0);
SECItem* item = new SECItem();
item->type = siBuffer;
item->data = data;
item->len = Length();

View File

@ -560,11 +560,7 @@ bool ReadAndEncodeAttribute(SECKEYPrivateKey* aKey,
CK_ATTRIBUTE_TYPE aAttribute,
Optional<nsString>& aDst)
{
ScopedSECItem item(::SECITEM_AllocItem(nullptr, nullptr, 0));
if (!item) {
return false;
}
ScopedSECItem item(new SECItem());
if (PK11_ReadRawAttribute(PK11_TypePrivKey, aKey, aAttribute, item)
!= SECSuccess) {
return false;