(edit_collect_completions): fix segmentation fault.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>