summaryrefslogtreecommitdiff
path: root/block
diff options
context:
space:
mode:
authorBen Hutchings <ben.hutchings@codethink.co.uk>2016-11-24 22:10:23 +0000
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2017-01-09 08:07:53 +0100
commit7fb5a936457dff3616644d1725f28002048819f7 (patch)
tree5442b13cc79706c942047271bf1cdb029eb29525 /block
parente321f384d8a58e546469cc8d3ca04257ef474d4c (diff)
kconfig/nconf: Fix hang when editing symbol with a long prompt
commit 79e51b5c2deea542b3bb8c66e0d502230b017dde upstream. Currently it is impossible to edit the value of a config symbol with a prompt longer than (terminal width - 2) characters. dialog_inputbox() calculates a negative x-offset for the input window and newwin() fails as this is invalid. It also doesn't check for this failure, so it busy-loops calling wgetch(NULL) which immediately returns -1. The additions in the offset calculations also don't match the intended size of the window. Limit the window size and calculate the offset similarly to show_scroll_win(). Fixes: 692d97c380c6 ("kconfig: new configuration interface (nconfig)") Signed-off-by: Ben Hutchings <ben.hutchings@codethink.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'block')
0 files changed, 0 insertions, 0 deletions