Borland C++ found these
This commit is contained in:
parent
320b95ea4f
commit
2e42fa62b6
18
edit.c
18
edit.c
@ -5,7 +5,7 @@
|
||||
|
||||
#include "sh.h"
|
||||
|
||||
__RCSID("$MirOS: src/bin/mksh/edit.c,v 1.104 2007/06/21 16:04:46 tg Exp $");
|
||||
__RCSID("$MirOS: src/bin/mksh/edit.c,v 1.105 2007/07/01 21:10:27 tg Exp $");
|
||||
|
||||
/* tty driver characters we are interested in */
|
||||
typedef struct {
|
||||
@ -1681,7 +1681,7 @@ x_delete(int nc, int push)
|
||||
nw += j;
|
||||
}
|
||||
nb = cp - xcp;
|
||||
nc = i;
|
||||
/* nc = i; */
|
||||
|
||||
if (xmp != NULL && xmp > xcp) {
|
||||
if (xcp + nb > xmp)
|
||||
@ -1783,7 +1783,7 @@ x_bword(void)
|
||||
static int
|
||||
x_fword(int move)
|
||||
{
|
||||
int nb = 0, nc = 0;
|
||||
int nc = 0;
|
||||
char *cp = xcp, *cp2;
|
||||
|
||||
if (cp == xep) {
|
||||
@ -1791,14 +1791,10 @@ x_fword(int move)
|
||||
return 0;
|
||||
}
|
||||
while (x_arg--) {
|
||||
while (cp != xep && is_mfs(*cp)) {
|
||||
while (cp != xep && is_mfs(*cp))
|
||||
cp++;
|
||||
nb++;
|
||||
}
|
||||
while (cp != xep && !is_mfs(*cp)) {
|
||||
while (cp != xep && !is_mfs(*cp))
|
||||
cp++;
|
||||
nb++;
|
||||
}
|
||||
}
|
||||
for (cp2 = xcp; cp2 < cp; ++nc)
|
||||
utf_ptradj(cp2, &cp2);
|
||||
@ -2780,7 +2776,7 @@ static int
|
||||
x_expand(int c __unused)
|
||||
{
|
||||
char **words;
|
||||
int nwords = 0;
|
||||
int nwords;
|
||||
int start, end;
|
||||
int is_command;
|
||||
int i;
|
||||
@ -5240,7 +5236,7 @@ static int
|
||||
complete_word(int cmd, int count)
|
||||
{
|
||||
static struct edstate *buf;
|
||||
int rval = 0;
|
||||
int rval;
|
||||
int nwords;
|
||||
int start, end;
|
||||
char **words;
|
||||
|
6
funcs.c
6
funcs.c
@ -5,7 +5,7 @@
|
||||
|
||||
#include "sh.h"
|
||||
|
||||
__RCSID("$MirOS: src/bin/mksh/funcs.c,v 1.57 2007/06/06 23:41:23 tg Exp $");
|
||||
__RCSID("$MirOS: src/bin/mksh/funcs.c,v 1.58 2007/07/01 21:10:28 tg Exp $");
|
||||
|
||||
int
|
||||
c_cd(const char **wp)
|
||||
@ -513,7 +513,7 @@ c_command(const char **wp)
|
||||
int
|
||||
c_typeset(const char **wp)
|
||||
{
|
||||
struct block *l = e->loc;
|
||||
struct block *l;
|
||||
struct tbl *vp, **p;
|
||||
Tflag fset = 0, fclr = 0;
|
||||
int thing = 0, func = 0, localv = 0;
|
||||
@ -1974,7 +1974,7 @@ c_set(const char **wp)
|
||||
{
|
||||
int argi, setargs;
|
||||
struct block *l = e->loc;
|
||||
const char **owp = wp;
|
||||
const char **owp;
|
||||
|
||||
if (wp[1] == NULL) {
|
||||
static const char *args [] = { "set", "-", NULL };
|
||||
|
10
histrap.c
10
histrap.c
@ -3,7 +3,7 @@
|
||||
|
||||
#include "sh.h"
|
||||
|
||||
__RCSID("$MirOS: src/bin/mksh/histrap.c,v 1.50 2007/07/01 17:13:52 tg Exp $");
|
||||
__RCSID("$MirOS: src/bin/mksh/histrap.c,v 1.51 2007/07/01 21:10:28 tg Exp $");
|
||||
|
||||
Trap sigtraps[NSIG + 1];
|
||||
static struct sigaction Sigact_ign;
|
||||
@ -38,7 +38,7 @@ int
|
||||
c_fc(const char **wp)
|
||||
{
|
||||
struct shf *shf;
|
||||
struct temp *tf = NULL;
|
||||
struct temp *tf;
|
||||
const char *p;
|
||||
char *editor = NULL;
|
||||
int gflag = 0, lflag = 0, nflag = 0, sflag = 0, rflag = 0;
|
||||
@ -360,11 +360,9 @@ hist_get(const char *str, int approx, int allow_cur)
|
||||
int anchored = *str == '?' ? (++str, 0) : 1;
|
||||
|
||||
/* the -1 is to avoid the current fc command */
|
||||
n = findhist(histptr - history - 1, 0, str, anchored);
|
||||
if (n < 0) {
|
||||
if ((n = findhist(histptr - history - 1, 0, str, anchored)) < 0)
|
||||
bi_errorf("%s: not in history", str);
|
||||
hp = NULL;
|
||||
} else
|
||||
else
|
||||
hp = &history[n];
|
||||
}
|
||||
return hp;
|
||||
|
3
main.c
3
main.c
@ -13,7 +13,7 @@
|
||||
#include <locale.h>
|
||||
#endif
|
||||
|
||||
__RCSID("$MirOS: src/bin/mksh/main.c,v 1.81 2007/07/01 19:04:53 tg Exp $");
|
||||
__RCSID("$MirOS: src/bin/mksh/main.c,v 1.82 2007/07/01 21:10:29 tg Exp $");
|
||||
|
||||
extern char **environ;
|
||||
|
||||
@ -1024,7 +1024,6 @@ check_fd(const char *name, int mode, const char **emsgp)
|
||||
int fd, fl;
|
||||
|
||||
if (ksh_isdigit(name[0]) && !name[1]) {
|
||||
fd = name[0] - '0';
|
||||
if ((fl = fcntl(fd = name[0] - '0', F_GETFL, 0)) < 0) {
|
||||
if (emsgp)
|
||||
*emsgp = "bad file descriptor";
|
||||
|
4
syn.c
4
syn.c
@ -2,7 +2,7 @@
|
||||
|
||||
#include "sh.h"
|
||||
|
||||
__RCSID("$MirOS: src/bin/mksh/syn.c,v 1.15 2007/06/22 23:34:42 tg Exp $");
|
||||
__RCSID("$MirOS: src/bin/mksh/syn.c,v 1.16 2007/07/01 21:10:29 tg Exp $");
|
||||
|
||||
struct nesting_state {
|
||||
int start_token; /* token than began nesting (eg, FOR) */
|
||||
@ -858,7 +858,7 @@ static int
|
||||
dbtestp_isa(Test_env *te, Test_meta meta)
|
||||
{
|
||||
int c = tpeek(ARRAYVAR | (meta == TM_BINOP ? 0 : CONTIN));
|
||||
int uqword = 0;
|
||||
int uqword;
|
||||
char *save = NULL;
|
||||
int ret = 0;
|
||||
|
||||
|
4
var.c
4
var.c
@ -2,7 +2,7 @@
|
||||
|
||||
#include "sh.h"
|
||||
|
||||
__RCSID("$MirOS: src/bin/mksh/var.c,v 1.39 2007/06/06 23:28:17 tg Exp $");
|
||||
__RCSID("$MirOS: src/bin/mksh/var.c,v 1.40 2007/07/01 21:10:29 tg Exp $");
|
||||
|
||||
/*
|
||||
* Variables
|
||||
@ -814,7 +814,7 @@ is_wdvarassign(const char *s)
|
||||
char **
|
||||
makenv(void)
|
||||
{
|
||||
struct block *l = e->loc;
|
||||
struct block *l;
|
||||
XPtrV env;
|
||||
struct tbl *vp, **vpp;
|
||||
int i;
|
||||
|
Loading…
x
Reference in New Issue
Block a user