mirror of
https://github.com/fish-shell/fish-shell.git
synced 2026-06-06 17:31:14 -03:00
Fix a memory leak
This commit is contained in:
@@ -1895,7 +1895,7 @@ void complete(const wcstring &cmd, std::vector<completion_t> &comps, complete_ty
|
||||
Get the string to complete
|
||||
*/
|
||||
|
||||
current_token = wcsndup(tok_begin, cursor_pos-(tok_begin-cmd_cstr));
|
||||
current_token.assign(tok_begin, cursor_pos-(tok_begin-cmd_cstr));
|
||||
|
||||
if (prev_begin)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user