]> git.saurik.com Git - apple/security.git/blobdiff - OSX/libsecurity_cdsa_utilities/lib/cssmdb.h
Security-59754.80.3.tar.gz
[apple/security.git] / OSX / libsecurity_cdsa_utilities / lib / cssmdb.h
index 66c9bcb285e7d5d26fa3cfc585b1f8b58202cff3..be227a3b8a56dd8b7e385d10d1b03f70d347a3d9 100644 (file)
@@ -220,9 +220,7 @@ class CssmDLPolyData
 public:
        CssmDLPolyData(const CSSM_DATA &data, CSSM_DB_ATTRIBUTE_FORMAT format)
        : mData(CssmData::overlay(data))
-#ifndef NDEBUG
     , mFormat(format)
-#endif 
     {}
 
        // @@@ Don't use assert, but throw an exception.
@@ -269,9 +267,7 @@ public:
 
 private:
        const CssmData &mData;
-#ifndef NDEBUG
        CSSM_DB_ATTRIBUTE_FORMAT mFormat;
-#endif
 };
 
 
@@ -686,6 +682,8 @@ public:
                const CSSM_NET_ADDRESS *location = NULL)
                : mImpl(new Impl(CssmSubserviceUid(guid, NULL, ssid, sstype), name, location)) { }
 
+    DLDbIdentifier(const DLDbIdentifier& i) : mImpl(i.mImpl) {}
+
        // Conversion Operators
        bool operator !() const { return !mImpl; }
        operator bool() const { return mImpl; }
@@ -749,7 +747,10 @@ struct DLDbFlatIdentifier {
                address(const_cast<CssmNetAddress *>(ident.dbLocation()))
                { }
 
-    operator DLDbIdentifier () { return DLDbIdentifier(*uid, name, address); }
+    operator DLDbIdentifier () {
+        DLDbIdentifier db(*uid, name, address);
+        return db;
+    }
 };
 
 template<class Action>