[Kolab-devel] my current patchset
hede <[email protected]> Fri, 01 Dec 2017 21:02:14 +0100
| Newsgroups | gmane.comp.kde.devel.kolab |
|---|---|
| Message-ID | <[email protected]> |
Hi all, sorry for asking this stupid question; I'm pretty sure I should know the answer. But what's the currently favoured way to send patches for review? In the past I usually uploaded my changes as some home repo to OBS, but those patches hardly arrived to the upstream repository (some arrived to OBS, others indeed to the upstream git repo, but others are still missing at all); on the other hand it seems I'm not allowed to use my own branch on git/diffusion. So here we go... (btw: one half of those patches are not initially made by me - they're found elsewhere on the net so maybe it's indeed harder to get them upstream as it should be) regards hede _______________________________________________ devel mailing list [email protected] https://lists.kolab.org/mailman/listinfo/devel
cyrus-imapd-2.5.11.41_fsigned-char_with_ARM_builds.patch
(text/x-diff, 1.1 KB)
diff -rupN cyrus-imapd-2.5.11.41.old/configure.ac cyrus-imapd-2.5.11.41/configure.ac
--- cyrus-imapd-2.5.11.41.old/configure.ac 2017-07-24 13:37:45.000000000 +0000
+++ cyrus-imapd-2.5.11.41/configure.ac 2017-12-01 14:03:13.000000000 +0000
@@ -84,6 +84,10 @@ AS_IF([test "x$enable_coverage" = "xyes"
AC_SUBST(COV_CFLAGS)
AC_SUBST(COV_LDFLAGS)
+if test $(uname -m) = "armv7l"; then
+ CFLAGS="${CFLAGS} -fsigned-char"
+fi
+
AC_ARG_WITH(login,,AC_MSG_ERROR([--with-login is no longer supported.
Configure SASL appropriately instead.]))
diff -rupN cyrus-imapd-2.5.11.41.old/debian/changelog cyrus-imapd-2.5.11.41/debian/changelog
--- cyrus-imapd-2.5.11.41.old/debian/changelog 2017-12-01 14:03:21.000000000 +0000
+++ cyrus-imapd-2.5.11.41/debian/changelog 2017-12-01 14:03:13.000000000 +0000
@@ -1,3 +1,9 @@
+cyrus-imapd (2.5.11.41-0~kolab2mic1) unstable; urgency=low
+
+ * add -fsigned-char to CFLAGS for fixing ARM builds
+
+ -- hede <[email protected]> Tue, 04 Nov 2017 15:30:23 +0100
+
cyrus-imapd (2.5.11.41-0~kolab2) unstable; urgency=low
* Fix potential non-writeable /dev/null and consequences
erlang-3.21.1-fix_readlink_for_relative_path_names.patch
(text/x-diff, 1.7 KB)
diff -rupN erlang-relx-3.21.1.ori/debian/changelog erlang-relx-3.21.1/debian/changelog --- erlang-relx-3.21.1.ori/debian/changelog 2017-12-01 13:58:10.000000000 +0000 +++ erlang-relx-3.21.1/debian/changelog 2017-12-01 13:58:25.000000000 +0000 @@ -1,3 +1,8 @@ +erlang-relx (3.21.1-1mic1) unstable; urgency=low + + * fix readlink for relative path names + + -- hede <[email protected]> Thu, 03 Nov 2017 22:26:56 +0000 erlang-relx (3.21.1-1) unstable; urgency=low * Initial Release. diff -rupN erlang-relx-3.21.1.ori/priv/templates/bin erlang-relx-3.21.1/priv/templates/bin --- erlang-relx-3.21.1.ori/priv/templates/bin 2016-10-07 18:33:29.000000000 +0000 +++ erlang-relx-3.21.1/priv/templates/bin 2017-12-01 13:58:25.000000000 +0000 @@ -2,7 +2,17 @@ set -e -SCRIPT=$(readlink $0 || true) +# SCRIPT=$(readlink $0 || true) +# OSX does not support readlink '-f' flag, work +# around that +case $OSTYPE in + darwin*) + SCRIPT=$(readlink $0 || true) + ;; + *) + SCRIPT=$(readlink -f $0 || true) + ;; +esac if [ -z $SCRIPT ]; then SCRIPT=$0 fi; diff -rupN erlang-relx-3.21.1.ori/priv/templates/extended_bin erlang-relx-3.21.1/priv/templates/extended_bin --- erlang-relx-3.21.1.ori/priv/templates/extended_bin 2016-10-07 18:33:29.000000000 +0000 +++ erlang-relx-3.21.1/priv/templates/extended_bin 2017-12-01 13:58:25.000000000 +0000 @@ -2,7 +2,17 @@ set -e -SCRIPT=$(readlink $0 || true) +# SCRIPT=$(readlink $0 || true) +# OSX does not support readlink '-f' flag, work +# around that +case $OSTYPE in + darwin*) + SCRIPT=$(readlink $0 || true) + ;; + *) + SCRIPT=$(readlink -f $0 || true) + ;; +esac if [ -z $SCRIPT ]; then SCRIPT=$0 fi;
guam-0.9.2-stalling-client-buffer-and-split-command-handling.patch
(text/x-diff, 5 KB)
diff -rupN guam-0.9.2/apps/kolab_guam/src/kolab_guam_session.erl guam-0.9.2-mic2/apps/kolab_guam/src/kolab_guam_session.erl
--- guam-0.9.2/apps/kolab_guam/src/kolab_guam_session.erl 2017-03-21 10:20:48.000000000 +0000
+++ guam-0.9.2-mic2/apps/kolab_guam/src/kolab_guam_session.erl 2017-11-30 19:16:12.994244345 +0000
@@ -195,25 +195,47 @@ process_client_data(Socket, Data, #state
{ TLS, Socket, NewInflator, NewDeflator, UndecidedRules, ActiveRules, <<>>, undefined, undefined };
nochange ->
%%lager:debug("... now applying rules"),
+ %lager:info("now applying rules..."),
{ ModifiedData, NewSplitCommand, NewSplitResetTrigger, NewUndecidedRules, NewActiveRules, PostAction } = apply_ruleset_clientside(ImapSession, Socket, PreprocessData, CurrentCommandSplit, UndecidedRules, ActiveRules),
%%lager:info("The modified data is: ~s", [ModifiedData]),
%lager:info("The post-processed data is: ~s", [PostProcessed]),
BufferThisData =
case PostAction of
perform_passthrough ->
+ %lager:info("sending (no buffer): ~s", [ModifiedData]),
eimap:passthrough_data(ImapSession, ModifiedData),
<<>>;
buffer_data ->
- Data
+ %Data
+ % Originally Aaron uses Data here, but later on this buffer is assumed to be
+ % already decoded, so we do have to use PreprocessData here, I think.
+ case binary:matches(PreprocessData, <<"\r\n">>) of
+ [] ->
+ lager:info("buffering: ~s", [PreprocessData]),
+ PreprocessData;
+ List ->
+ {FoundPos, _} = lists:last(List),
+ % I would like to have some binary:match for the last instead of the
+ % first occurrence; but I'm really inexperienced in erlang so I don't
+ % know how to solve this efficient, so I'm using binary:matches with
+ % using the last element only
+ SplitPos = FoundPos + 2,
+ eimap:passthrough_data(ImapSession, binary:part(PreprocessData, 0, SplitPos)),
+ %lager:info("sending first part: ~s", [binary:part(PreprocessData, 0, SplitPos)] ),
+ %lager:info("buffering second part: ~s", [binary:part(PreprocessData, SplitPos, size(PreprocessData)-SplitPos)]),
+ binary:part(PreprocessData, SplitPos, size(PreprocessData)-SplitPos)
+ end
end,
{ TLS, Socket, Inflator, Deflator, NewUndecidedRules, NewActiveRules, BufferThisData, NewSplitCommand, NewSplitResetTrigger }
end,
set_socket_active(TLSActive, CurrentSocket),
- PrevBuffered = State#state.buffered_client_data,
+ %buffered_client_data is already in DataToBuffer via preprocess_client_data
+ %PrevBuffered = State#state.buffered_client_data,
{ noreply, State#state{ rules_deciding = CurrentUndecidedRules, rules_active = CurrentActiveRules,
socket = CurrentSocket, client_tls_active = TLSActive,
inflator = CurrentInflator, deflator = CurrentDeflator,
- buffered_client_data = <<PrevBuffered/binary, DataToBuffer/binary>>,
+ %buffered_client_data = <<PrevBuffered/binary, DataToBuffer/binary>>,
+ buffered_client_data = <<DataToBuffer/binary>>,
current_command_split = SplitCommand,
command_split_reset_trigger = SplitResetTrigger } }.
@@ -261,7 +283,7 @@ apply_next_rule_serverside(ImapSession,
apply_next_rule_serverside(ImapSession, ModifiedData, [{ Module, ModifiedRuleState } | ActiveRulesAcc], ActiveRules).
apply_ruleset_clientside(_ImapSession, _Socket, ClientData, _CurrentCommandSplit, [], []) ->
- { ClientData, [], [], [], [], perform_passthrough };
+ { ClientData, undefined, [], [], [], perform_passthrough };
apply_ruleset_clientside(ImapSession, Socket, ClientData, CurrentCommandSplit, UndecidedRules, CurrentlyActiveRules) ->
{ PostAction, SplitCommand, SplitResetTrigger } =
case CurrentCommandSplit of
diff -rupN guam-0.9.2/debian/changelog guam-0.9.2-mic2/debian/changelog
--- guam-0.9.2/debian/changelog 2017-12-01 10:23:48.000000000 +0000
+++ guam-0.9.2-mic2/debian/changelog 2017-11-30 17:32:36.954428454 +0000
@@ -1,3 +1,15 @@
+guam (0.9.2-3mic2) unstable; urgency=medium
+
+ * split command handling
+
+ -- hede <[email protected]> Thu, 30 Nov 2017 18:36:43 +0100
+
+guam (0.9.2-3mic1) unstable; urgency=medium
+
+ * workaround for stalling client buffer
+
+ -- hede <[email protected]> Thu, 30 Nov 2017 17:30:23 +0100
+
guam (0.9.2-3) unstable; urgency=medium
* Rebuild
pykolab-0.8.7-tcp_keepalive_in_virtual_containers_T2094.patch
(text/x-diff, 2.7 KB)
diff -rupN pykolab-0.8.7.ori/debian/changelog pykolab-0.8.7/debian/changelog --- pykolab-0.8.7.ori/debian/changelog 2017-12-01 14:00:51.000000000 +0000 +++ pykolab-0.8.7/debian/changelog 2017-12-01 14:01:09.000000000 +0000 @@ -1,3 +1,9 @@ +pykolab (0.8.7-0~kolab2mic1) unstable; urgency=low + + * Direct access to kernel /proc/sys/net/ipv4/tcp_keepalive* not available in virtual containers (T2094) + + -- hede <[email protected]> Sat, 04 Nov 2017 15:47:00 +0100 + pykolab (0.8.7-0~kolab2) unstable; urgency=low * pykolab requires now python-pymysql because /usr/lib/postfix/kolab_smtp_access_policy needs module pymysql on Ubuntu Xenial diff -rupN pykolab-0.8.7.ori/pykolab/imap/__init__.py pykolab-0.8.7/pykolab/imap/__init__.py --- pykolab-0.8.7.ori/pykolab/imap/__init__.py 2016-12-13 13:02:01.000000000 +0000 +++ pykolab-0.8.7/pykolab/imap/__init__.py 2017-12-01 14:01:09.000000000 +0000 @@ -848,14 +848,26 @@ class IMAP(object): def _set_socket_keepalive(self, sock): sock.setsockopt(socket.SOL_SOCKET, socket.SO_KEEPALIVE, 1) - with open('/proc/sys/net/ipv4/tcp_keepalive_time', 'r') as f: - sock.setsockopt(socket.IPPROTO_TCP, socket.TCP_KEEPIDLE, (int)(f.read())) + try: + with open('/proc/sys/net/ipv4/tcp_keepalive_time', 'r') as f: + sock.setsockopt(socket.IPPROTO_TCP, socket.TCP_KEEPIDLE, (int)(f.read())) + except IOError: + # Kernel did not expose reqeusted file; set as default instead. + sock.setsockopt(socket.IPPROTO_TCP, socket.TCP_KEEPIDLE, 7200) - with open('/proc/sys/net/ipv4/tcp_keepalive_intvl', 'r') as f: - sock.setsockopt(socket.IPPROTO_TCP, socket.TCP_KEEPINTVL, (int)(f.read())) + try: + with open('/proc/sys/net/ipv4/tcp_keepalive_intvl', 'r') as f: + sock.setsockopt(socket.IPPROTO_TCP, socket.TCP_KEEPINTVL, (int)(f.read())) + except IOError: + # Kernel did not expose reqeusted file; set as default instead. + sock.setsockopt(socket.IPPROTO_TCP, socket.TCP_KEEPINTVL, 75) - with open('/proc/sys/net/ipv4/tcp_keepalive_probes', 'r') as f: - sock.setsockopt(socket.IPPROTO_TCP, socket.TCP_KEEPCNT, (int)(f.read())) + try: + with open('/proc/sys/net/ipv4/tcp_keepalive_probes', 'r') as f: + sock.setsockopt(socket.IPPROTO_TCP, socket.TCP_KEEPCNT, (int)(f.read())) + except IOError: + # Kernel did not expose reqeusted file; set as default instead. + sock.setsockopt(socket.IPPROTO_TCP, socket.TCP_KEEPCNT, 9) def _set_kolab_mailfolder_acls(self, acls, folder=None, update=False): # special case, folder has no ACLs assigned and update was requested,