From: Jay Freeman (saurik) Date: Sat, 11 Jan 2014 15:28:46 +0000 (-0800) Subject: Call through to rl_redisplay to update line state. X-Git-Tag: v0.9.500~75 X-Git-Url: https://git.saurik.com/cycript.git/commitdiff_plain/05f619c271e3e78e20c66eee1f1dbbf1a4492e26?ds=inline Call through to rl_redisplay to update line state. --- diff --git a/Display.cpp b/Display.cpp index cafdc57..402e717 100644 --- a/Display.cpp +++ b/Display.cpp @@ -38,6 +38,7 @@ typedef std::complex CYCursor; +extern "C" int rl_display_fixed; extern "C" int _rl_vis_botlin; extern "C" int _rl_last_c_pos; extern "C" int _rl_last_v_pos; @@ -121,6 +122,9 @@ void CYDisplayStart(int meta) { } void CYDisplayUpdate() { + rl_display_fixed = 1; + rl_redisplay(); + #if RL_READLINE_VERSION >= 0x0600 const char *prompt(rl_display_prompt); #else @@ -147,10 +151,6 @@ void CYDisplayUpdate() { _rl_last_c_pos = current_.imag(); _rl_last_v_pos = target.real(); - // XXX: readline crashes trying to avoid an empty line if this is left at 0 :( - if (_rl_last_c_pos == 0) - _rl_last_c_pos = 1; - if (current_.imag() == 0) CYDisplayOutput(putchar, width, " "); putp(clr_eos);