Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2012-04-09 08:39:47 +0400
committerCampbell Barton <ideasman42@gmail.com>2012-04-09 08:39:47 +0400
commit9a6a791ff0c9b32f66831f5e09d7c283ac309b95 (patch)
tree0777f6caf5134d5d3e3babf7757340cb06d83686 /source/blender/makesrna/RNA_types.h
parentb7113002dbea417617e3ef655d42732ade16577e (diff)
fix [#30865] Crash when browsing last operators in outliner (or by Python API)
Operator descriptions can be NULL pointers, fix this by making use of PROP_NEVER_NULL flag, when its not set, generated string funcs will test for NULL.
Diffstat (limited to 'source/blender/makesrna/RNA_types.h')
-rw-r--r--source/blender/makesrna/RNA_types.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/source/blender/makesrna/RNA_types.h b/source/blender/makesrna/RNA_types.h
index 8a668f68761..8f3e2c1f104 100644
--- a/source/blender/makesrna/RNA_types.h
+++ b/source/blender/makesrna/RNA_types.h
@@ -180,6 +180,9 @@ typedef enum PropertyFlag {
/* disallow assigning a variable to its self, eg an object tracking its self
* only apply this to types that are derived from an ID ()*/
PROP_ID_SELF_CHECK = 1<<20,
+ /* use for...
+ * - pointers: in the UI and python so unsetting or setting to None won't work
+ * - strings: so our internal generated get/length/set functions know to do NULL checks before access [#30865] */
PROP_NEVER_NULL = 1<<18,
/* currently only used for UI, this is similar to PROP_NEVER_NULL
* except that the value may be NULL at times, used for ObData, where an Empty's will be NULL