diff options
author | Ton Roosendaal <ton@blender.org> | 2007-04-24 18:52:35 +0400 |
---|---|---|
committer | Ton Roosendaal <ton@blender.org> | 2007-04-24 18:52:35 +0400 |
commit | 46545ac575e500d46aae3fabb05f6d46a7fb1797 (patch) | |
tree | 1fc020f78bbe1300e243068fd8665f26097c6661 /source/blender/makesdna/DNA_ID.h | |
parent | 1ad4f024c8d73ead1867378d33bba47689473087 (diff) |
64 bits safety:
- makesdna now checks for struct-in-struct alignment (default 8 byte align)
- fixed two occurances of such struct-in-struct align errors
Diffstat (limited to 'source/blender/makesdna/DNA_ID.h')
-rw-r--r-- | source/blender/makesdna/DNA_ID.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/source/blender/makesdna/DNA_ID.h b/source/blender/makesdna/DNA_ID.h index ce03bdc5e84..14e39faf2c6 100644 --- a/source/blender/makesdna/DNA_ID.h +++ b/source/blender/makesdna/DNA_ID.h @@ -57,15 +57,15 @@ typedef struct IDProperty { char name[32]; char type, subtype; short flag; - IDPropertyData data; + int saved; /*saved is used to indicate if this struct has been saved yet. + seemed like a good idea as a pad var was needed anyway :)*/ + IDPropertyData data; /* note, alignment for 64 bits */ int len; /* array length, also (this is important!) string length + 1. the idea is to be able to reuse array realloc functions on strings.*/ /*totallen is total length of allocated array/string, including a buffer. Note that the buffering is mild; the code comes from python's list implementation.*/ int totallen; /*strings and arrays are both buffered, though the buffer isn't saved. at least it won't be when I write that code. :)*/ - int saved; /*saved is used to indicate if this struct has been saved yet. - seemed like a good idea as a pad var was needed anyway :)*/ } IDProperty; #define MAX_IDPROP_NAME 32 |