More minor nits (mostly using memove instead of memcpy).

This commit is contained in:
Steve Price 1997-08-08 00:54:05 +00:00
parent 242fa23c9c
commit 880fdc3dd9
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=27970
6 changed files with 13 additions and 16 deletions

View File

@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)csh.h 8.1 (Berkeley) 5/31/93
* $Id: csh.h,v 1.4 1997/02/22 14:01:41 peter Exp $
* $Id: csh.h,v 1.5 1997/08/07 21:42:04 steve Exp $
*/
/*
@ -187,8 +187,8 @@ jmp_buf reslab;
#define setexit() (setjmp(reslab))
#define reset() longjmp(reslab, 1)
/* Should use structure assignment here */
#define getexit(a) memcpy(((char *)(a)), (char *)reslab, sizeof reslab)
#define resexit(a) memcpy((char *)reslab, (char *)(a), sizeof reslab)
#define getexit(a) memmove((char *)(a), (char *)reslab, sizeof reslab)
#define resexit(a) memmove((char *)reslab, (char *)(a), sizeof reslab)
Char *gointr; /* Label for an onintr transfer */
@ -421,8 +421,6 @@ struct varent {
#define v_right v_link[1]
#define v_parent v_link[2]
struct varent *adrof1();
#define adrof(v) adrof1(v, &shvhed)
#define value(v) value1(v, &shvhed)

View File

@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)extern.h 8.1 (Berkeley) 5/31/93
* $Id$
* $Id: extern.h,v 1.4 1997/02/22 14:01:53 peter Exp $
*/
#include <sys/cdefs.h>
@ -161,7 +161,7 @@ Char *globone __P((Char *, int));
int Gmatch __P((Char *, Char *));
void ginit __P((void));
Char **globall __P((Char **));
void rscan __P((Char **, void (*)()));
void rscan __P((Char **, void (*)(int)));
void tglob __P((Char **));
void trim __P((Char **));
#ifdef FILEC

View File

@ -36,7 +36,7 @@
static char sccsid[] = "@(#)func.c 8.1 (Berkeley) 5/31/93";
#else
static const char rcsid[] =
"$Id: func.c,v 1.7 1997/02/22 14:01:55 peter Exp $";
"$Id: func.c,v 1.8 1997/08/07 21:42:09 steve Exp $";
#endif
#endif /* not lint */
@ -1206,7 +1206,6 @@ getval(lp, v)
Char **v;
{
float f;
double atof();
Char *cp = *v++;
f = atof(short2str(cp));
@ -1371,7 +1370,7 @@ dosuspend(v, t)
{
int ctpgrp;
void (*old) ();
void (*old) __P((int));
if (loginsh)
stderror(ERR_SUSPLOG);

View File

@ -36,7 +36,7 @@
static char sccsid[] = "@(#)glob.c 8.1 (Berkeley) 5/31/93";
#else
static const char rcsid[] =
"$Id: glob.c,v 1.8 1997/02/22 14:01:58 peter Exp $";
"$Id: glob.c,v 1.9 1997/08/07 21:42:09 steve Exp $";
#endif
#endif /* not lint */
@ -557,7 +557,7 @@ ginit()
void
rscan(t, f)
Char **t;
void (*f) ();
void (*f) __P((int));
{
Char *p;

View File

@ -36,7 +36,7 @@
static char sccsid[] = "@(#)lex.c 8.1 (Berkeley) 5/31/93";
#else
static const char rcsid[] =
"$Id: lex.c,v 1.6 1997/02/22 14:02:01 peter Exp $";
"$Id: lex.c,v 1.7 1997/08/07 21:42:11 steve Exp $";
#endif
#endif /* not lint */
@ -1508,7 +1508,7 @@ bgetc()
goto again;
}
if (c > 0)
memcpy(fbuf[buf] + off, ttyline, c * sizeof(Char));
memmove(fbuf[buf] + off, ttyline, c * sizeof(Char));
numleft = 0;
}
else {

View File

@ -36,7 +36,7 @@
static char sccsid[] = "@(#)proc.c 8.1 (Berkeley) 5/31/93";
#else
static const char rcsid[] =
"$Id: proc.c,v 1.4 1997/02/22 14:02:06 peter Exp $";
"$Id: proc.c,v 1.5 1997/08/07 21:42:15 steve Exp $";
#endif
#endif /* not lint */
@ -1172,7 +1172,7 @@ pfind(cp)
}
if (np)
return (np);
stderror((ERR_NAME | cp[1]) == '?' ? ERR_JOBPAT : ERR_NOSUCHJOB);
stderror(ERR_NAME | (cp[1] == '?' ? ERR_JOBPAT : ERR_NOSUCHJOB));
/* NOTREACHED */
return (0);
}