summaryrefslogtreecommitdiff
path: root/src/cmd/8c/txt.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/cmd/8c/txt.c')
-rw-r--r--src/cmd/8c/txt.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/cmd/8c/txt.c b/src/cmd/8c/txt.c
index 0dd387d11..b2e0148a0 100644
--- a/src/cmd/8c/txt.c
+++ b/src/cmd/8c/txt.c
@@ -397,6 +397,10 @@ regsalloc(Node *n, Node *nn)
void
regaalloc1(Node *n, Node *nn)
{
+ if(REGARG < 0) {
+ fatal(n, "regaalloc1 and REGARG<0");
+ return;
+ }
nodreg(n, nn, REGARG);
reg[REGARG]++;
curarg = align(curarg, nn->type, Aarg1, nil);