Blender Git Commit Log

Git Commits -> Revision 9e05f65

Revision 9e05f65 by Sergey Sharybin (master)
May 29, 2013, 11:49 (GMT)
Make sure bool will always have the same size in C and C++

There were an issues with data structures defined in headers
and being used by both C and C++ on systems with stdbool
unavailable.

This happened because bool in this case will be defined as
unsigned int, which is 4 bytes. But C++'s bool is only 1
byte and this lead to alignment issues.

Now bool is always 1 byte, also made sure there's no situation
like bool foo = BitField & BitFlag, which could give overflow
issues. Use (BitField & BitFlag) != 0 instead.

Fixes #35553: Compositor broken (Backdrop & Preview)

Commit Details:

Full Hash: 9e05f6571f824bd4a99bb4fe5af5ec15688a9649
SVN Revision: 57102
Parent Commit: e99801d
Lines Changed: +13, -16

9 Modified Paths:

/source/blender/blenlib/BLI_sys_types.h (+2, -5) (Diff)
/source/blender/bmesh/intern/bmesh_mesh.c (+1, -1) (Diff)
/source/blender/editors/animation/anim_draw.c (+3, -3) (Diff)
/source/blender/editors/interface/interface_widgets.c (+2, -2) (Diff)
/source/blender/editors/space_buttons/buttons_texture.c (+1, -1) (Diff)
/source/blender/editors/space_view3d/view3d_fly.c (+1, -1) (Diff)
/source/blender/imbuf/intern/png.c (+1, -1) (Diff)
/source/blender/modifiers/intern/MOD_bevel.c (+1, -1) (Diff)
/source/blender/render/intern/source/pipeline.c (+1, -1) (Diff)
By: Miika HämäläinenLast update: Nov-07-2014 14:18MiikaHweb | 2003-2021