Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F117892575
D5007.1775365766.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Authored By
Unknown
Size
1 KB
Referenced Files
None
Subscribers
None
D5007.1775365766.diff
View Options
diff --git a/lib/kolab_sync_storage.php b/lib/kolab_sync_storage.php
--- a/lib/kolab_sync_storage.php
+++ b/lib/kolab_sync_storage.php
@@ -1942,7 +1942,7 @@
$rcube = rcube::get_instance();
$db = $rcube->get_dbh();
$this->relations[$folderid][$synctime] = $relations;
- $data = rcube_charset::clean(json_encode($relations));
+ $data = gzdeflate(json_encode($relations));
$result = $db->insert_or_update(
'syncroton_relations_state',
@@ -2001,11 +2001,15 @@
}
if ($row) {
- // Don't use $row['synctime'] for the internal cache.
+ // Don't use $row['synctime'] for the internal cache, and use $synctime instead.
// The synctime of the found row is usually earlier than the requested synctime.
- // Note: We use internal cache because there's a call to both hasChanges() and
+ // Note: We use the internal cache because there's a call to both hasChanges() and
// getChangedEntries() in Sync. It's needed until we add some caching on a higher level.
- $this->relations[$folderid][$synctime] = json_decode($row['data'], true);
+ $data = $row['data'];
+ $inflated = gzinflate($data)
+ // Inflation may fail for backward compatiblity
+ $data = $inflated ? $inflated : $data;
+ $this->relations[$folderid][$synctime] = json_decode($data, true);
// Cleanup: remove all records older than the current one.
// We must use the row's synctime, otherwise we would delete the record we just loaded
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Sun, Apr 5, 5:09 AM (16 h, 46 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
18832428
Default Alt Text
D5007.1775365766.diff (1 KB)
Attached To
Mode
D5007: Compress the data in syncroton_relations_state
Attached
Detach File
Event Timeline