--- weechat-0.3.2.orig/src/gui/gui-completion.c	2010-04-08 16:05:14.000000000 +0200
+++ weechat-0.3.2/src/gui/gui-completion.c	2010-07-15 16:41:35.415870907 +0200
@@ -1658,7 +1658,7 @@ gui_completion_build_list (struct t_gui_
     }
     if (repeat_last)
     {
-        pos_space = rindex (HOOK_COMMAND(ptr_hook, completion), ' ');
+        pos_space = strrchr (HOOK_COMMAND(ptr_hook, completion), ' ');
         gui_completion_build_list_template (completion,
                                             (pos_space) ?
                                             pos_space + 1 : HOOK_COMMAND(ptr_hook,
