Fix: RNA: Failing assert on console auto-complete
Looks like this was caused by 3de916ca25.
Steps to reproduce were:
- Switch to the Scripting workspace
- Paste:
`C.screen.areas[5].spaces[0].rna_type.properties['show_region_asset_shelf'].`
- Press tab
The RNA property getter should always return a value, even when empty.
That's what other such getters do as well.
This commit is contained in:
@@ -912,6 +912,9 @@ static void rna_Property_deprecated_note_get(PointerRNA *ptr, char *value)
|
||||
if (const DeprecatedRNA *deprecated = RNA_property_deprecated(prop)) {
|
||||
strcpy(value, deprecated->note);
|
||||
}
|
||||
else {
|
||||
value[0] = '\0';
|
||||
}
|
||||
}
|
||||
|
||||
static void rna_Property_deprecated_version_get(PointerRNA *ptr, int *value)
|
||||
|
||||
Reference in New Issue
Block a user