Fix T83296: Unknown actions no longer perform an undo push

str_len_clip is initialized to 0, so when "Unknown Action"
occurs, set str_len_clip appropriately.
Regression in 0688309988

Ref D9759
This commit is contained in:
Greg Neumiller 2020-12-07 13:32:36 +11:00 committed by Campbell Barton
parent c2a01a6c11
commit 3d0b65f89b
Notes: blender-bot 2023-02-14 11:00:17 +01:00
Referenced by issue #83296, 2.91 regression: Changing a node's color wheel, color ramp stops, or curves no longer pushes UNDO to the stack.
Referenced by issue #83216, Potential candidates for corrective releases
1 changed files with 1 additions and 0 deletions

View File

@ -838,6 +838,7 @@ static void ui_apply_but_undo(uiBut *but)
/* fallback, else we don't get an undo! */
if (str == NULL || str[0] == '\0' || str_len_clip == 0) {
str = "Unknown Action";
str_len_clip = strlen(str);
}
/* Optionally override undo when undo system doesn't support storing properties. */