[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: ptrdiff_t overflow checks for malloc-posix etc.

From: Bruno Haible
Subject: Re: ptrdiff_t overflow checks for malloc-posix etc.
Date: Sun, 18 Apr 2021 22:32:50 +0200
User-agent: KMail/5.1.3 (Linux/4.4.0-206-generic; KDE/5.18.0; x86_64; ; )

Paul Eggert wrote:
> > For example, if my package never calls malloc (0) but desires portability
> > to native Windows, would I want that *every* malloc call on *all*
> > non-glibc platforms goes through hoops before it reaches the malloc()
> > function in libc?
> I would want that, yes, because that'd be more reliable than what we 
> were doing. Any performance penalty on non-GNU platforms is surely 
> insignificant in real applications, and so is outweighed by the 
> reliability improvement.

I don't disagree — as I can't measure reliability quantitatively.
Just wanted to give the reasoning that had led to the existing distinction
between 'malloc-posix' and 'malloc-gnu'.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]