[Top][All Lists]

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

Re: Another patch (warning)

From: Paul Eggert
Subject: Re: Another patch (warning)
Date: Thu, 21 Jun 2018 12:34:49 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.8.0

On 06/20/2018 12:34 PM, Bruce Korb wrote:
random_r.c:289:13: warning: cast from 'char *' to 'int32_t *' (aka 'int *') increases required alignment from 1 to 4

Thanks for reporting the warning. As Eric mentioned, this is a bug in random_r.c that can cause crashes. I reproduced one such crash and installed the attached patches. The first two merely merge changes from glibc and cleanup, the last one fixes the bug and adds a test case.

Attachment: 0001-random-random_r-merge-from-glibc.patch
Description: Text Data

Attachment: 0002-random_r-omit-unnecessary-include.patch
Description: Text Data

Attachment: 0003-random_r-do-not-crash-if-state-is-unaligned.patch
Description: Text Data

reply via email to

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