mirror of
https://github.com/Kunzisoft/KeePassDX.git
synced 2026-11-30 13:52:58 -08:00
fix: custom data in group (fix KeeShare) #1335
This commit is contained in:
1 parent
9aa1d11b94
commit
6e1c8e5bec
6 files changed
+5
-5
No files matched your search
@@ -855,10 +855,6 @@ class DatabaseKDBX : DatabaseVersioned<UUID, UUID, GroupKDBX, EntryKDBX> {
|
||||
mFieldReferenceEngine.clear()
|
||||
}
|
||||
|
||||
fun containsPublicCustomData(): Boolean {
|
||||
return publicCustomData.size() > 0
|
||||
}
|
||||
|
||||
fun buildNewBinaryAttachment(smallSize: Boolean,
|
||||
compression: Boolean,
|
||||
protection: Boolean,
|
||||
|
||||
+1
-1
@@ -92,7 +92,7 @@ constructor(private val databaseKDBX: DatabaseKDBX,
|
||||
writeHeaderField(DatabaseHeaderKDBX.PwDbHeaderV4Fields.InnerRandomStreamID, uIntTo4Bytes(header.innerRandomStream!!.id))
|
||||
}
|
||||
|
||||
if (databaseKDBX.containsPublicCustomData()) {
|
||||
if (databaseKDBX.publicCustomData.size() > 0) {
|
||||
val bos = ByteArrayOutputStream()
|
||||
VariantDictionary.serialize(databaseKDBX.publicCustomData, bos)
|
||||
writeHeaderField(DatabaseHeaderKDBX.PwDbHeaderV4Fields.PublicCustomData, bos.toByteArray())
|
||||
|
||||
@@ -359,6 +359,7 @@ class DatabaseOutputKDBX(private val mDatabaseKDBX: DatabaseKDBX,
|
||||
writeBoolean(DatabaseKDBXXML.ElemEnableAutoType, group.enableAutoType)
|
||||
writeBoolean(DatabaseKDBXXML.ElemEnableSearching, group.enableSearching)
|
||||
writeUuid(DatabaseKDBXXML.ElemLastTopVisibleEntry, group.lastTopVisibleEntry)
|
||||
writeCustomData(group.customData)
|
||||
}
|
||||
|
||||
@Throws(IllegalArgumentException::class, IllegalStateException::class, IOException::class)
|
||||
|
||||
Reference in new issue
Block a user