Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. =================================================================== RCS file: /ftp/cvs/cvsroot/src/lib/libedit/readline.c,v rcsdiff: /ftp/cvs/cvsroot/src/lib/libedit/readline.c,v: warning: Unknown phrases like `commitid ...;' are present. retrieving revision 1.99.2.1 retrieving revision 1.102 diff -u -p -r1.99.2.1 -r1.102 --- src/lib/libedit/readline.c 2012/04/17 00:05:27 1.99.2.1 +++ src/lib/libedit/readline.c 2012/05/15 17:30:04 1.102 @@ -1,4 +1,4 @@ -/* $NetBSD: readline.c,v 1.99.2.1 2012/04/17 00:05:27 yamt Exp $ */ +/* $NetBSD: readline.c,v 1.102 2012/05/15 17:30:04 christos Exp $ */ /*- * Copyright (c) 1997 The NetBSD Foundation, Inc. @@ -31,7 +31,7 @@ #include "config.h" #if !defined(lint) && !defined(SCCSID) -__RCSID("$NetBSD: readline.c,v 1.99.2.1 2012/04/17 00:05:27 yamt Exp $"); +__RCSID("$NetBSD: readline.c,v 1.102 2012/05/15 17:30:04 christos Exp $"); #endif /* not lint && not SCCSID */ #include @@ -1756,6 +1756,7 @@ rl_complete(int ignore __attribute__((__ #ifdef WIDECHAR static ct_buffer_t wbreak_conv, sprefix_conv; #endif + char *breakchars; if (h == NULL || e == NULL) rl_initialize(); @@ -1768,12 +1769,17 @@ rl_complete(int ignore __attribute__((__ return CC_REFRESH; } + if (rl_completion_word_break_hook != NULL) + breakchars = (*rl_completion_word_break_hook)(); + else + breakchars = rl_basic_word_break_characters; + /* Just look at how many global variables modify this operation! */ return fn_complete(e, (CPFunction *)rl_completion_entry_function, rl_attempted_completion_function, ct_decode_string(rl_basic_word_break_characters, &wbreak_conv), - ct_decode_string(rl_special_prefixes, &sprefix_conv), + ct_decode_string(breakchars, &sprefix_conv), _rl_completion_append_character_function, (size_t)rl_completion_query_items, &rl_completion_type, &rl_attempted_completion_over,