This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH] Improve check against integer wraparound in hcreate_r [BZ #18240]
- From: Szabolcs Nagy <szabolcs dot nagy at arm dot com>
- To: Florian Weimer <fweimer at redhat dot com>, Paul Eggert <eggert at cs dot ucla dot edu>
- Cc: GNU C Library <libc-alpha at sourceware dot org>, Adhemerval Zanella <adhemerval dot zanella at linaro dot org>, <nd at arm dot com>
- Date: Mon, 1 Feb 2016 16:44:10 +0000
- Subject: Re: [PATCH] Improve check against integer wraparound in hcreate_r [BZ #18240]
- Authentication-results: sourceware.org; auth=none
- Nodisclaimer: True
- References: <56A210C4 dot 80609 at redhat dot com> <56A42D78 dot 1030506 at cs dot ucla dot edu> <877fixs9or dot fsf at mid dot deneb dot enyo dot de> <56A6B883 dot 2070801 at cs dot ucla dot edu> <56A8F5C0 dot 2070307 at redhat dot com>
- Spamdiagnosticmetadata: NSPM
- Spamdiagnosticoutput: 1:23
On 27/01/16 16:52, Florian Weimer wrote:
> 2016-01-27 Florian Weimer <fweimer@redhat.com>
>
> [BZ #18240]
> * misc/bug18240.c: New test.
this test now times out for me on aarch64 hw
> + test_size (INT_MAX - 2);
this test case allocates a big buffer (INT_MAX*24)
with calloc and it actually tries to memset it to 0.
when i tried a simple example manually that worked:
calloc did not try to memset 48 GB to 0.
i think the test-skeleton changes malloc behaviour
in weird ways, but i'm not yet sure what's going on.
(i did not notice earlier as in my normal test
environment memory overcommit is off so the
test case just fails with ENOMEM, i'm not sure
how to handle such tests where huge memory is
allocated)