This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
| Other format: | [Raw text] | |
On 11 Mar 2015 14:00, James Lemke wrote:
> On 03/01/2015 10:08 PM, Mike Frysinger wrote:
> > On 04 Feb 2015 13:56, James Lemke wrote:
> >> --- a/malloc/hooks.c
> >> +++ b/malloc/hooks.c
> >> +{
> >> + unsigned char magic;
> >> +
> >> + magic = (((size_t) p >> 3) ^ ((size_t) p >> 11)) & 0xFF;
> >
> > shouldn't you use uintptr_t instead of size_t ?
>
> It is size_t because that's what the previous macro implementation used.
> I don't see a strong reason to change the casts to uinptr_t,
> but if you do I'll change them.
uintptr_t is the only type you can safely cast a pointer, but if the rest of the
code is already using size_t, no need to change that in this commit
-mike
Attachment:
signature.asc
Description: Digital signature
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |