Thu Sep 1 13:23:44 2016 UTC ()
fix typo


(mbalmer)
diff -r1.137 -r1.138 src/lib/libedit/readline.c

cvs diff -r1.137 -r1.138 src/lib/libedit/readline.c (expand / switch to unified diff)

--- src/lib/libedit/readline.c 2016/08/24 13:10:59 1.137
+++ src/lib/libedit/readline.c 2016/09/01 13:23:44 1.138
@@ -1,14 +1,14 @@ @@ -1,14 +1,14 @@
1/* $NetBSD: readline.c,v 1.137 2016/08/24 13:10:59 christos Exp $ */ 1/* $NetBSD: readline.c,v 1.138 2016/09/01 13:23:44 mbalmer Exp $ */
2 2
3/*- 3/*-
4 * Copyright (c) 1997 The NetBSD Foundation, Inc. 4 * Copyright (c) 1997 The NetBSD Foundation, Inc.
5 * All rights reserved. 5 * All rights reserved.
6 * 6 *
7 * This code is derived from software contributed to The NetBSD Foundation 7 * This code is derived from software contributed to The NetBSD Foundation
8 * by Jaromir Dolecek. 8 * by Jaromir Dolecek.
9 * 9 *
10 * Redistribution and use in source and binary forms, with or without 10 * Redistribution and use in source and binary forms, with or without
11 * modification, are permitted provided that the following conditions 11 * modification, are permitted provided that the following conditions
12 * are met: 12 * are met:
13 * 1. Redistributions of source code must retain the above copyright 13 * 1. Redistributions of source code must retain the above copyright
14 * notice, this list of conditions and the following disclaimer. 14 * notice, this list of conditions and the following disclaimer.
@@ -21,27 +21,27 @@ @@ -21,27 +21,27 @@
21 * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 21 * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
22 * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS 22 * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
23 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 23 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
24 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 24 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
25 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 25 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
26 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 26 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
27 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 27 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
28 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 28 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
29 * POSSIBILITY OF SUCH DAMAGE. 29 * POSSIBILITY OF SUCH DAMAGE.
30 */ 30 */
31 31
32#include "config.h" 32#include "config.h"
33#if !defined(lint) && !defined(SCCSID) 33#if !defined(lint) && !defined(SCCSID)
34__RCSID("$NetBSD: readline.c,v 1.137 2016/08/24 13:10:59 christos Exp $"); 34__RCSID("$NetBSD: readline.c,v 1.138 2016/09/01 13:23:44 mbalmer Exp $");
35#endif /* not lint && not SCCSID */ 35#endif /* not lint && not SCCSID */
36 36
37#include <sys/types.h> 37#include <sys/types.h>
38#include <sys/stat.h> 38#include <sys/stat.h>
39#include <ctype.h> 39#include <ctype.h>
40#include <dirent.h> 40#include <dirent.h>
41#include <errno.h> 41#include <errno.h>
42#include <fcntl.h> 42#include <fcntl.h>
43#include <limits.h> 43#include <limits.h>
44#include <pwd.h> 44#include <pwd.h>
45#include <setjmp.h> 45#include <setjmp.h>
46#include <stdint.h> 46#include <stdint.h>
47#include <stdio.h> 47#include <stdio.h>
@@ -361,27 +361,27 @@ rl_initialize(void) @@ -361,27 +361,27 @@ rl_initialize(void)
361 361
362 /* 362 /*
363 * Allow the use of the Delete/Insert keys. 363 * Allow the use of the Delete/Insert keys.
364 */ 364 */
365 el_set(e, EL_BIND, "\\e[3~", "ed-delete-next-char", NULL); 365 el_set(e, EL_BIND, "\\e[3~", "ed-delete-next-char", NULL);
366 el_set(e, EL_BIND, "\\e[2~", "ed-quoted-insert", NULL); 366 el_set(e, EL_BIND, "\\e[2~", "ed-quoted-insert", NULL);
367 367
368 /* 368 /*
369 * Ctrl-left-arrow and Ctrl-right-arrow for word moving. 369 * Ctrl-left-arrow and Ctrl-right-arrow for word moving.
370 */ 370 */
371 el_set(e, EL_BIND, "\\e[1;5C", "em-next-word", NULL); 371 el_set(e, EL_BIND, "\\e[1;5C", "em-next-word", NULL);
372 el_set(e, EL_BIND, "\\e[1;5D", "ed-prev-word", NULL); 372 el_set(e, EL_BIND, "\\e[1;5D", "ed-prev-word", NULL);
373 el_set(e, EL_BIND, "\\e[5C", "em-next-word", NULL); 373 el_set(e, EL_BIND, "\\e[5C", "em-next-word", NULL);
374 el_set(e, EL_BIND, "\\e[5D", "ed-erev-word", NULL); 374 el_set(e, EL_BIND, "\\e[5D", "ed-prev-word", NULL);
375 el_set(e, EL_BIND, "\\e\\e[C", "em-next-word", NULL); 375 el_set(e, EL_BIND, "\\e\\e[C", "em-next-word", NULL);
376 el_set(e, EL_BIND, "\\e\\e[D", "ed-prev-word", NULL); 376 el_set(e, EL_BIND, "\\e\\e[D", "ed-prev-word", NULL);
377 377
378 /* read settings from configuration file */ 378 /* read settings from configuration file */
379 el_source(e, NULL); 379 el_source(e, NULL);
380 380
381 /* 381 /*
382 * Unfortunately, some applications really do use rl_point 382 * Unfortunately, some applications really do use rl_point
383 * and rl_line_buffer directly. 383 * and rl_line_buffer directly.
384 */ 384 */
385 _resize_fun(e, &rl_line_buffer); 385 _resize_fun(e, &rl_line_buffer);
386 _rl_update_pos(); 386 _rl_update_pos();
387 387