diff options
author | Marvin.Haeuser@outlook.com <Marvin.Haeuser@outlook.com> | 2018-11-01 04:08:35 +0800 |
---|---|---|
committer | Liming Gao <liming.gao@intel.com> | 2018-11-02 22:15:54 +0800 |
commit | 498cb29dfdcc7232f7b0693e266555c19c43ae20 (patch) | |
tree | 6a4ad28f86252c97a2b02633acf4873e3822d2c8 /BaseTools/Source/Python/Workspace/MetaFileTable.py | |
parent | 88e8498f8a72cff1f7af6852ec8166772913399e (diff) | |
download | edk2-498cb29dfdcc7232f7b0693e266555c19c43ae20.tar.gz edk2-498cb29dfdcc7232f7b0693e266555c19c43ae20.tar.bz2 edk2-498cb29dfdcc7232f7b0693e266555c19c43ae20.zip |
MdePkg/Base.h: Implement BASE_CR() via OFFSET_OF().
Replace the current NULL pointer dereference to retrieve Field's
offset with a call to OFFSET_OF(). This is implemented via
__builtin_offsetof for GCC and Clang, which eliminates UB caught by
Clang UndefinedBehaviorSanitizer.
Contributed-under: TianoCore Contribution Agreement 1.1
Signed-off-by: Marvin Haeuser <Marvin.Haeuser@outlook.com>
Reviewed-by: Liming Gao <liming.gao@intel.com>
Diffstat (limited to 'BaseTools/Source/Python/Workspace/MetaFileTable.py')
0 files changed, 0 insertions, 0 deletions