little things
This commit is contained in:
parent
e21fee604e
commit
1aa4e9c82e
5 changed files with 14 additions and 2069 deletions
|
|
@ -82,6 +82,7 @@ int procrfork(void (*f)(void *arg), void *arg, unsigned int stacksize, int flag
|
||||||
void** procdata(void);
|
void** procdata(void);
|
||||||
void threadexec(Channel *, int[3], char *, char *[]);
|
void threadexec(Channel *, int[3], char *, char *[]);
|
||||||
void threadexecl(Channel *, int[3], char *, ...);
|
void threadexecl(Channel *, int[3], char *, ...);
|
||||||
|
int threadspawn(int[3], char*, char*[]);
|
||||||
int recv(Channel *c, void *v);
|
int recv(Channel *c, void *v);
|
||||||
void* recvp(Channel *c);
|
void* recvp(Channel *c);
|
||||||
unsigned long recvul(Channel *c);
|
unsigned long recvul(Channel *c);
|
||||||
|
|
|
||||||
|
|
@ -12,13 +12,6 @@ DIRS=`ls -l |sed -n 's/^d.* //p' |egrep -v "^($BUGGERED)$"`
|
||||||
|
|
||||||
dir-all dir-install: $PLAN9/bin/9yacc
|
dir-all dir-install: $PLAN9/bin/9yacc
|
||||||
|
|
||||||
XLIB=draw bio 9
|
|
||||||
$O.clock: clock.$O ${XLIB:%=$PLAN9/lib/lib%.a}
|
|
||||||
$LD -o $target $prereq -L$X11/lib -lX11
|
|
||||||
|
|
||||||
$O.tweak: tweak.$O ${XLIB:%=$PLAN9/lib/lib%.a}
|
|
||||||
$LD -o $target $prereq -L$X11/lib -lX11
|
|
||||||
|
|
||||||
%.tab.h %.tab.c: %.y
|
%.tab.h %.tab.c: %.y
|
||||||
$YACC $YFLAGS -s $stem $prereq
|
$YACC $YFLAGS -s $stem $prereq
|
||||||
|
|
||||||
|
|
|
||||||
2058
src/cmd/tweak.c
2058
src/cmd/tweak.c
File diff suppressed because it is too large
Load diff
|
|
@ -96,7 +96,9 @@ __xtoplan9kbd(XEvent *e)
|
||||||
k = '\n';
|
k = '\n';
|
||||||
break;
|
break;
|
||||||
case XK_Alt_L:
|
case XK_Alt_L:
|
||||||
|
case XK_Meta_L: /* Shift Alt on PCs */
|
||||||
case XK_Alt_R:
|
case XK_Alt_R:
|
||||||
|
case XK_Meta_R: /* Shift Alt on PCs */
|
||||||
k = Kalt;
|
k = Kalt;
|
||||||
break;
|
break;
|
||||||
default: /* not ISO-1 or tty control */
|
default: /* not ISO-1 or tty control */
|
||||||
|
|
@ -117,7 +119,6 @@ __xtoplan9kbd(XEvent *e)
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* BUG: could/should do Alt translation here! */
|
|
||||||
return k+0;
|
return k+0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
#include "threadimpl.h"
|
#include "threadimpl.h"
|
||||||
|
|
||||||
static void efork(int[3], int[2], char*, char**);
|
static void efork(int[3], int[2], char*, char**);
|
||||||
static void
|
static int
|
||||||
_threadexec(Channel *pidc, int fd[3], char *prog, char *args[], int freeargs)
|
_threadexec(Channel *pidc, int fd[3], char *prog, char *args[], int freeargs)
|
||||||
{
|
{
|
||||||
int pfd[2];
|
int pfd[2];
|
||||||
|
|
@ -63,18 +63,26 @@ _threadexec(Channel *pidc, int fd[3], char *prog, char *args[], int freeargs)
|
||||||
sendul(pidc, pid);
|
sendul(pidc, pid);
|
||||||
|
|
||||||
_threaddebug(DBGEXEC, "threadexec schedexecwait");
|
_threaddebug(DBGEXEC, "threadexec schedexecwait");
|
||||||
threadexits(0);
|
return pid;
|
||||||
|
|
||||||
Bad:
|
Bad:
|
||||||
_threaddebug(DBGEXEC, "threadexec bad %r");
|
_threaddebug(DBGEXEC, "threadexec bad %r");
|
||||||
if(pidc)
|
if(pidc)
|
||||||
sendul(pidc, ~0);
|
sendul(pidc, ~0);
|
||||||
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
threadexec(Channel *pidc, int fd[3], char *prog, char *args[])
|
threadexec(Channel *pidc, int fd[3], char *prog, char *args[])
|
||||||
{
|
{
|
||||||
_threadexec(pidc, fd, prog, args, 0);
|
if(_threadexec(pidc, fd, prog, args, 0) >= 0)
|
||||||
|
threadexits(nil);
|
||||||
|
}
|
||||||
|
|
||||||
|
int
|
||||||
|
threadspawn(int fd[3], char *prog, char *args[])
|
||||||
|
{
|
||||||
|
return _threadexec(nil, fd, prog, args, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue