aboutsummaryrefslogtreecommitdiff
path: root/src/libregexp
diff options
context:
space:
mode:
authorRuss Cox <rsc@swtch.com>2008-05-10 13:36:05 -0400
committerRuss Cox <rsc@swtch.com>2008-05-10 13:36:05 -0400
commit002d2f2610604626d672fd45eb79d75059028da3 (patch)
tree9022af617dbba44b3cc87cb5d711a6cf75cc1d64 /src/libregexp
parent66f6e2b651124387f83b9af17104a79d6d93f67b (diff)
downloadplan9port-002d2f2610604626d672fd45eb79d75059028da3.tar.gz
plan9port-002d2f2610604626d672fd45eb79d75059028da3.tar.bz2
plan9port-002d2f2610604626d672fd45eb79d75059028da3.zip
libregexp: more placating of gcc (John Gosset)
Diffstat (limited to 'src/libregexp')
-rw-r--r--src/libregexp/regcomp.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/libregexp/regcomp.c b/src/libregexp/regcomp.c
index b8286dc7..0dabd4f0 100644
--- a/src/libregexp/regcomp.c
+++ b/src/libregexp/regcomp.c
@@ -261,18 +261,18 @@ optimize(Reprog *pp)
case STAR:
case PLUS:
case QUEST:
- *(char**)(void*)&inst->u1.right += diff;
+ inst->u1.right = (void*)((char*)inst->u1.right + diff);
break;
case CCLASS:
case NCCLASS:
- *(char**)(void*)&inst->u1.right += diff;
+ inst->u1.right = (void*)((char*)inst->u1.right + diff);
cl = inst->u1.cp;
- *(char**)(void*)&cl->end += diff;
+ cl->end = (void*)((char*)cl->end + diff);
break;
}
- *(char**)(void*)&inst->u2.left += diff;
+ inst->u2.left = (void*)((char*)inst->u2.left + diff);
}
- *(char**)(void*)&npp->startinst += diff;
+ npp->startinst = (void*)((char*)npp->startinst + diff);
return npp;
}