fix the “dramsey horizontal scrolling bug” – time for you to find another ☺

This commit is contained in:
tg 2007-05-10 19:08:48 +00:00
parent d89613399b
commit 384032b729
3 changed files with 14 additions and 6 deletions

View File

@ -1,4 +1,4 @@
# $MirOS: src/bin/mksh/check.t,v 1.101 2007/04/23 21:46:12 tg Exp $
# $MirOS: src/bin/mksh/check.t,v 1.102 2007/05/10 19:08:47 tg Exp $
# $OpenBSD: bksl-nl.t,v 1.2 2001/01/28 23:04:56 niklas Exp $
# $OpenBSD: history.t,v 1.5 2001/01/28 23:04:56 niklas Exp $
# $OpenBSD: read.t,v 1.3 2003/03/10 03:48:16 david Exp $
@ -7,7 +7,7 @@
# http://www.research.att.com/~gsf/public/ifs.sh
expected-stdout:
@(#)MIRBSD KSH R29 2007/04/17
@(#)MIRBSD KSH R29 2007/05/10
description:
Check version of shell.
category: pdksh

12
edit.c
View File

@ -5,7 +5,7 @@
#include "sh.h"
__RCSID("$MirOS: src/bin/mksh/edit.c,v 1.89 2007/05/10 18:58:31 tg Exp $");
__RCSID("$MirOS: src/bin/mksh/edit.c,v 1.90 2007/05/10 19:08:48 tg Exp $");
/* tty driver characters we are interested in */
typedef struct {
@ -2832,8 +2832,16 @@ do_complete(int flags, /* XCF_{COMMAND,FILE,COMMAND_FILE} */
x_print_expansions(nwords, words, is_command);
completed = 1;
}
if (completed)
if (completed) {
/*
* I don't quite get it: the x_goto(xcp) call is equivalent to
* x_adjust() if we are ASCII-only and "heading off screen",
* but putting x_adjust() here instead of x_goto(xcp) does not
* fix the dramsey horizontal scrolling bug. Weird.
*/
x_goto(xcp);
x_redraw(0);
}
x_free_words(nwords, words);
}

4
sh.h
View File

@ -8,8 +8,8 @@
/* $OpenBSD: c_test.h,v 1.4 2004/12/20 11:34:26 otto Exp $ */
/* $OpenBSD: tty.h,v 1.5 2004/12/20 11:34:26 otto Exp $ */
#define MKSH_SH_H_ID "$MirOS: src/bin/mksh/sh.h,v 1.127 2007/04/24 10:42:02 tg Exp $"
#define MKSH_VERSION "R29 2007/04/17"
#define MKSH_SH_H_ID "$MirOS: src/bin/mksh/sh.h,v 1.128 2007/05/10 19:08:48 tg Exp $"
#define MKSH_VERSION "R29 2007/05/10"
#if HAVE_SYS_PARAM_H
#include <sys/param.h>