Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/lib/libedit Always use el->el_buffer, because newbuffer coul...



details:   https://anonhg.NetBSD.org/src/rev/459da664795c
branches:  trunk
changeset: 554847:459da664795c
user:      christos <christos%NetBSD.org@localhost>
date:      Sun Nov 02 20:08:41 2003 +0000

description:
Always use el->el_buffer, because newbuffer could have moved. From
Gerry Swislow gerry at certif dot com

diffstat:

 lib/libedit/chared.c |  6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diffs (27 lines):

diff -r 25337be7a212 -r 459da664795c lib/libedit/chared.c
--- a/lib/libedit/chared.c      Sun Nov 02 20:07:58 2003 +0000
+++ b/lib/libedit/chared.c      Sun Nov 02 20:08:41 2003 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: chared.c,v 1.20 2003/10/18 23:48:42 christos Exp $     */
+/*     $NetBSD: chared.c,v 1.21 2003/11/02 20:08:41 christos Exp $     */
 
 /*-
  * Copyright (c) 1992, 1993
@@ -37,7 +37,7 @@
 #if 0
 static char sccsid[] = "@(#)chared.c   8.1 (Berkeley) 6/4/93";
 #else
-__RCSID("$NetBSD: chared.c,v 1.20 2003/10/18 23:48:42 christos Exp $");
+__RCSID("$NetBSD: chared.c,v 1.21 2003/11/02 20:08:41 christos Exp $");
 #endif
 #endif /* not lint && not SCCSID */
 
@@ -578,7 +578,7 @@
                return 0;
 
        /* Safe to set enlarged buffer size */
-       el->el_line.limit  = &newbuffer[newsz - EL_LEAVE];
+       el->el_line.limit  = &el->el_line.buffer[newsz - EL_LEAVE];
        return 1;
 }
 



Home | Main Index | Thread Index | Old Index