]> jfr.im git - irc/weechat/weechat.git/commit
spell: fix refresh of bar item "spell_suggest" when the input becomes empty (closes...
authorSébastien Helleu <redacted>
Fri, 13 Nov 2020 20:26:16 +0000 (21:26 +0100)
committerSébastien Helleu <redacted>
Fri, 13 Nov 2020 20:30:06 +0000 (21:30 +0100)
commiteb90a73fe811e2de0e0646abf10242e639a7b1a1
tree0321a9367f92c4c8b21bc7fc5c97da78aecafb3a
parent4065d32e685ad0db1c46dc245ed067d3786d3d09
spell: fix refresh of bar item "spell_suggest" when the input becomes empty (closes #1586)

When the input is empty, length of string is zero: when sending zero to
function weechat_string_dyn_alloc, the function returns NULL and therefore we
return immediately instead of handling the empty input, which is a valid value.

The regression was introduced by the use of dynamic strings, commit:
299f74bfef9e0d239ad141a4df3b2dcf11a4c0da
ChangeLog.adoc
src/plugins/spell/spell.c