mirror of
https://github.com/weechat/weechat.git
synced 2026-07-03 16:23:14 +02:00
Fixed crash with Ctrl-T (transpose) and one char on line (bug #18153)
This commit is contained in:
@@ -1,10 +1,11 @@
|
||||
WeeChat - Wee Enhanced Environment for Chat
|
||||
===========================================
|
||||
|
||||
ChangeLog - 2006-10-24
|
||||
ChangeLog - 2006-10-30
|
||||
|
||||
|
||||
Version 0.2.2 (under dev!):
|
||||
* fixed crash with Ctrl-T (transpose) and one char on line (bug #18153)
|
||||
* added "modifier" in plugins API
|
||||
* improved /plugin command
|
||||
* fixed bug on ignore with "mode" IRC command (bug #18058)
|
||||
|
||||
@@ -414,7 +414,8 @@ gui_action_transpose_chars (t_gui_window *window)
|
||||
|
||||
if (window->buffer->has_input)
|
||||
{
|
||||
if (window->buffer->input_buffer_pos > 0)
|
||||
if ((window->buffer->input_buffer_pos > 0)
|
||||
&& (window->buffer->input_buffer_length > 1))
|
||||
{
|
||||
if (window->buffer->input_buffer_pos == window->buffer->input_buffer_length)
|
||||
window->buffer->input_buffer_pos--;
|
||||
|
||||
+2
-1
@@ -1,10 +1,11 @@
|
||||
WeeChat - Wee Enhanced Environment for Chat
|
||||
===========================================
|
||||
|
||||
ChangeLog - 2006-10-24
|
||||
ChangeLog - 2006-10-30
|
||||
|
||||
|
||||
Version 0.2.2 (under dev!):
|
||||
* fixed crash with Ctrl-T (transpose) and one char on line (bug #18153)
|
||||
* added "modifier" in plugins API
|
||||
* improved /plugin command
|
||||
* fixed bug on ignore with "mode" IRC command (bug #18058)
|
||||
|
||||
@@ -414,7 +414,8 @@ gui_action_transpose_chars (t_gui_window *window)
|
||||
|
||||
if (window->buffer->has_input)
|
||||
{
|
||||
if (window->buffer->input_buffer_pos > 0)
|
||||
if ((window->buffer->input_buffer_pos > 0)
|
||||
&& (window->buffer->input_buffer_length > 1))
|
||||
{
|
||||
if (window->buffer->input_buffer_pos == window->buffer->input_buffer_length)
|
||||
window->buffer->input_buffer_pos--;
|
||||
|
||||
Reference in New Issue
Block a user