]> git.ipfire.org Git - thirdparty/asterisk.git/commit
cli: Fix ast_el_read_char to work with libedit >= 3.1 11/4411/1
authorGeorge Joseph <gjoseph@digium.com>
Mon, 14 Nov 2016 18:16:03 +0000 (11:16 -0700)
committerGeorge Joseph <gjoseph@digium.com>
Mon, 14 Nov 2016 18:20:26 +0000 (13:20 -0500)
commit5e0c22404316ecdf8e1510553474274eddf55e20
tree960df22d84ed39953736873d32d4dedcd20e9114
parentec17e96784b8a75f74d84621165c73d986d56f95
cli:  Fix ast_el_read_char to work with libedit >= 3.1

Libedit 3.1 is not build with unicode on as a default and so the
prototype for the el_gets callback changed from expecting a char buffer
to accepting a wchar buffer.  If ast_el_read_char isn't changed,
the cli reads garbage from teh terminal.

Added a configure test for (*el_rfunc_t)(EditLine *, wchar_t *) and
updated ast_el_read_char to use the HAVE_ define to detemrine whether
to use char or wchar.

ASTERISK-26592 #close

Change-Id: I9099b46f68e06d0202ff80e53022a2b68b08871a
configure
configure.ac
include/asterisk/autoconfig.h.in
main/asterisk.c