diff options
author | Donát Nagy <donat.nagy@ericsson.com> | 2023-08-04 16:39:40 +0200 |
---|---|---|
committer | Donát Nagy <donat.nagy@ericsson.com> | 2023-08-21 17:17:02 +0200 |
commit | 3e014038b373e5a4a96d89d46cea17e4d2456a04 (patch) | |
tree | 0f6a66709ddb8492b0eb729dd1544c4b8cbc0be2 /clang/lib/ExtractAPI/Serialization/SymbolGraphSerializer.cpp | |
parent | d0e1e7649b8d17aa7c064597419a739643ae6270 (diff) | |
download | llvm-3e014038b373e5a4a96d89d46cea17e4d2456a04.zip llvm-3e014038b373e5a4a96d89d46cea17e4d2456a04.tar.gz llvm-3e014038b373e5a4a96d89d46cea17e4d2456a04.tar.bz2 |
[analyzer] Improve underflow handling in ArrayBoundV2
This minor change ensures that underflow errors are reported on memory
regions that are in unknown space but have a well-defined beginning.
As a concrete example, the following test case did not produce a warning
previously, but will produce a warning after this patch:
typedef struct {
int id;
char name[256];
} user_t;
user_t *get_symbolic_user(void);
char test_underflow_symbolic_2() {
user_t *user = get_symbolic_user();
return user->name[-1];
}
Differential Revision: https://reviews.llvm.org/D157104
Diffstat (limited to 'clang/lib/ExtractAPI/Serialization/SymbolGraphSerializer.cpp')
0 files changed, 0 insertions, 0 deletions