commit | cf16b79238793bebd451b34838bbac2f299657ab | [log] [download] |
---|---|---|
author | Manuel Pégourié-Gonnard <manuel.pegourie-gonnard@arm.com> | Thu Dec 10 14:36:25 2015 +0100 |
committer | Simon Butcher <simon.butcher@arm.com> | Tue Dec 22 20:13:35 2015 +0000 |
tree | 7062cfa833e6c2cf7ed605eddafc9327ed750cdf | |
parent | e4ed3475b074025b38a5c5c8a7bad9a4f2232686 [diff] |
Avoid seemingly-possible overflow By looking just at that test, it looks like 2 + dn_size could overflow. In fact that can't happen as that would mean we've read a CA cert of size is too big to be represented by a size_t. However, it's best for code to be more obviously free of overflow without having to reason about the bigger picture.