From 82e0b7d1a69bda69a08141a3855dbec7f6d12978 Mon Sep 17 00:00:00 2001 From: spaced4ndy <8711996+spaced4ndy@users.noreply.github.com> Date: Fri, 8 Dec 2023 11:07:12 +0400 Subject: [PATCH] wip --- src/Simplex/Chat.hs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/Simplex/Chat.hs b/src/Simplex/Chat.hs index 727aacf893..ec49e76c5b 100644 --- a/src/Simplex/Chat.hs +++ b/src/Simplex/Chat.hs @@ -118,6 +118,11 @@ import qualified UnliftIO.Exception as E import UnliftIO.IO (hClose, hSeek, hTell, openFile) import UnliftIO.STM +-- this limit reserves space for metadata in forwarded messages +-- 15780 (limit used for fileChunkSize) - 161 (x.grp.msg.forward overhead) = 15619, round to 15610 +maxChatMsgSize :: Int64 +maxChatMsgSize = 15610 + defaultChatConfig :: ChatConfig defaultChatConfig = ChatConfig