~kris/9p

9hist

d85b360627db8025b03cde89ff48149043aaf95c — David du Colombier 33 years ago 6bef71f
Plan 9 from Bell Labs 1993-03-24
2 files changed, 5 insertions(+), 2 deletions(-)

M port/devpipe.c
M port/sysproc.c
M port/devpipe.c => port/devpipe.c +1 -1
@@ 170,7 170,7 @@ pipeopen(Chan *c, int omode)
	qunlock(p);
	poperror();

	c->mode = omode&~OTRUNC;
	c->mode = openmode(omode);
	c->flag |= COPEN;
	c->offset = 0;
	return c;

M port/sysproc.c => port/sysproc.c +4 -1
@@ 512,9 512,12 @@ sysdeath(ulong *arg)
long
syserrstr(ulong *arg)
{
	char tmp[ERRLEN];

	validaddr(arg[0], ERRLEN, 1);
	memmove(tmp, (char*)arg[0], ERRLEN);
	memmove((char*)arg[0], u->error, ERRLEN);
	strncpy(u->error, Enoerror, ERRLEN);
	memmove(u->error, tmp, ERRLEN);
	return 0;
}