https://bugzilla.samba.org/show_bug.cgi?id=12769

--- Comment #10 from MulticoreNOP <multicore...@mailbox.org> ---
(In reply to Simon Matter from comment #7)
#define MALLOC_MAX 0x100000000

is greater than uint32-MAX, therefore will overflow and result in an
unpredictable and unfriendly manner.

#define MALLOC_MAX 0xD09DC300
(~3,5GiB) leaves some space to detect a "just too big for this implementation"
and will fail gracefully.

Yet, the real culprit here is the use of "unsigned int" as opposed to size_t.

I therefore propose the attached patch that removes MALLOC_MAX in its entirety
and should allow arrays as big as available virtual memory can support.

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
-- 
Please use reply-all for most replies to avoid omitting the mailing list.
To unsubscribe or change options: https://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html

Reply via email to