]> git.proxmox.com Git - mirror_corosync.git/commit
totempg: Fix corrupted messages
authorRytis Karpuška <rytisk@neurotechnology.com>
Fri, 9 Feb 2018 14:00:19 +0000 (16:00 +0200)
committerJan Friesse <jfriesse@redhat.com>
Fri, 9 Feb 2018 16:38:05 +0000 (17:38 +0100)
commit105f3ae98c06f6a9ca4b5d5a9c1ea6d025115b79
tree9f6ec16eb590398dc541457e6a8c4a7cbc85974f
parent899cb299831fea479ca8bc64d99fb1fce215d795
totempg: Fix corrupted messages

Commit 899cb299831fea479ca8bc64d99fb1fce215d795 changed copy_len
to iovec[i].iov_len, assuming,
copy_len is always the same as iovec[i].iov_len under those
circumstances, but it missed the possability of small message being
partly put at the end of packet, which cuts this message in two parts
and therefore making copy_len not equal to iovec[i].iov_len.

This is revert of 899cb299831fea479ca8bc64d99fb1fce215d795

Signed-off-by: Rytis Karpuška <rytisk@neurotechnology.com>
Reviewed-by: Jan Friesse <jfriesse@redhat.com>
exec/totempg.c