Fix: Garbage string when searching in menu #112719

Closed
Pratik Borhade wants to merge 3 commits from PratikPB2123:search-type-query into main

When changing the target branch, be careful to rebase the branch in your fork to match. See documentation.
1 changed files with 1 additions and 1 deletions

View File

@ -1865,7 +1865,7 @@ static int wm_search_menu_invoke(bContext *C, wmOperator *op, const wmEvent *eve
}
{
char *buffer = RNA_string_get_alloc(op->ptr, "initial_query", nullptr, 0, nullptr);
STRNCPY(g_search_text, buffer);
BLI_strncpy_rlen(g_search_text, buffer, 2);
MEM_SAFE_FREE(buffer);
}
}