[openssl-users] Warnings Compiling openssl 1.0.2d
Jeffrey Walton
noloader at gmail.com
Tue Jul 21 20:57:12 UTC 2015
On Tue, Jul 21, 2015 at 4:40 PM, Tom Browder <tom.browder at gmail.com> wrote:
> On Tue, Jul 21, 2015 at 2:16 PM, Matt Caswell <matt at openssl.org> wrote:
>> On 21/07/15 15:33, Tom Browder wrote:
>>> On Sun, Jul 19, 2015 at 11:00 AM, Tom Browder <tom.browder at gmail.com> wrote:
>>> I lied. After rebuilding gcc 5.2.0 and rechecking I get the following
>>> warnings from building 1.0.2d:
>>>
>>> d1_both.c: In function 'dtls1_retransmit_message':
>>> d1_both.c:1261:9: warning: 'save_write_sequence' may be used
>>> uninitialized in this function [-Wmaybe-uninitialized]
>>> memcpy(s->s3->write_sequence, save_write_sequence,
>>> ^
>>
>> This one is entirely bogus. "save_write_sequence" is initialized on line
>> 1241. The compiler just isn't clever enough to figure that out.
>
> Um, that initialization is in an if block, so that's not guaranteed, right?
>
Was that a -Wmaybe-uninitialized?
A neat trick: open Configure, copy your linux-86_64 configure line,
rename it to something like linux-analyze, and then change the
compiler to ccc-analyze. ccc-analyze is LLVM's static analyzer, and it
gives you the graph of the steps that arrive at the conclusion.
Finally, run `./Configure linux-analyze`, `make` and then `make test'.
Then, copy/paste the output. You don't have to explain anything.
Jeff
More information about the openssl-users
mailing list