Various little fixes.

This commit is contained in:
rsc 2004-03-05 03:13:13 +00:00
parent c91bd3283a
commit 4da83e7cce
7 changed files with 13 additions and 7 deletions

5
plumb/initial.plumbing Normal file
View file

@ -0,0 +1,5 @@
# to update: cat $HOME/lib/plumbing | 9p write plumb/rules
editor = acme
include basic

View file

@ -45,7 +45,7 @@ Command *command;
void acmeerrorinit(void); void acmeerrorinit(void);
void readfile(Column*, char*); void readfile(Column*, char*);
int shutdown(void*, char*); static int shutdown(void*, char*);
void void
derror(Display *d, char *errorstr) derror(Display *d, char *errorstr)
@ -270,7 +270,7 @@ char *oknotes[] ={
int dumping; int dumping;
int static int
shutdown(void *v, char *msg) shutdown(void *v, char *msg)
{ {
int i; int i;

View file

@ -472,7 +472,7 @@ coldragwin(Column *c, Window *w, int but)
} }
/* is it a flick to the right? */ /* is it a flick to the right? */
if(abs(p.y-op.y)<10 && p.x>op.x+30 && rowwhichcol(c->row, p)==c) if(abs(p.y-op.y)<10 && p.x>op.x+30 && rowwhichcol(c->row, p)==c)
p.x += Dx(w->r); /* yes: toss to next column */ p.x = op.x+Dx(w->r); /* yes: toss to next column */
nc = rowwhichcol(c->row, p); nc = rowwhichcol(c->row, p);
if(nc!=nil && nc!=c){ if(nc!=nil && nc!=c){
colclose(c, w, FALSE); colclose(c, w, FALSE);

View file

@ -12,3 +12,4 @@ DIRS=`ls -l |sed -n 's/^d.* //p' |egrep -v "$BUGGERED"`
<$PLAN9/src/mkdirs <$PLAN9/src/mkdirs
dir-install: $PLAN9/bin/yacc

View file

@ -9,7 +9,7 @@ Plumbmsg m;
void void
usage(void) usage(void)
{ {
fprint(2, "usage: plumb [-p plumbfile] [-a 'attr=value ...'] [-s src] [-d dst] [-t type] [-w wdir] -i | data1\n"); fprint(2, "usage: plumb [-p plumbfile] [-a 'attr=value ...'] [-s src] [-d dst] [-t type] [-w wdir] -i | data1\n");
exits("usage"); exits("usage");
} }

View file

@ -201,7 +201,6 @@ _threadnalt++;
}else{ }else{
altexec(a, s); /* unlocks chanlock, does splx */ altexec(a, s); /* unlocks chanlock, does splx */
} }
_sched();
t->chan = Channone; t->chan = Channone;
_threadnalt++; _threadnalt++;
return a - alts; return a - alts;

View file

@ -146,10 +146,11 @@ pollidle(void *v)
for(i=0; i<npoll; i++) for(i=0; i<npoll; i++)
if(pfd[i].fd != -1 && pfd[i].revents){ if(pfd[i].fd != -1 && pfd[i].revents){
//fprint(2, " %d", pfd[i].fd); //fprint(2, " %d", pfd[i].fd);
nbsendul(polls[i].c, 1);
pfd[i].fd = -1; pfd[i].fd = -1;
pfd[i].events = 0; pfd[i].events = 0;
pfd[i].revents = 0; pfd[i].revents = 0;
nbsendul(polls[i].c, 1);
//fprint(2, " x%d", pfd[i].fd);
} }
//fprint(2, "\n"); //fprint(2, "\n");
} }
@ -192,7 +193,7 @@ _threadfdwait(int fd, int rw, ulong pc)
pfd[i].fd = fd; pfd[i].fd = fd;
pfd[i].events = rw=='r' ? POLLIN : POLLOUT; pfd[i].events = rw=='r' ? POLLIN : POLLOUT;
polls[i].c = &s.c; polls[i].c = &s.c;
//fprint(2, "%s [%3d] fdwait %d %c list *0x%lux\n", if(0) fprint(2, "%s [%3d] fdwait %d %c list *0x%lux\n",
argv0, threadid(), fd, rw, pc); argv0, threadid(), fd, rw, pc);
recvul(&s.c); recvul(&s.c);
} }