diff options
author | Otto Moerbeek <otto@cvs.openbsd.org> | 2007-10-03 08:15:30 +0000 |
---|---|---|
committer | Otto Moerbeek <otto@cvs.openbsd.org> | 2007-10-03 08:15:30 +0000 |
commit | a2f23a0f4539991c8472613441751eead15267e9 (patch) | |
tree | 1f0947be7f93fdd6637681912da00579191b3e5e | |
parent | ff022fbf64b28b0a5ce933da8fd3ce64ed234af1 (diff) |
pull from ragge's repo:
#include and obscure name clash fix. From From Laurent Desnogues.
-rw-r--r-- | usr.bin/pcc/mip/regs.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/usr.bin/pcc/mip/regs.c b/usr.bin/pcc/mip/regs.c index d4dd9ff452d..2caf9c66d23 100644 --- a/usr.bin/pcc/mip/regs.c +++ b/usr.bin/pcc/mip/regs.c @@ -1,4 +1,4 @@ -/* $OpenBSD: regs.c,v 1.7 2007/10/02 18:42:34 gilles Exp $ */ +/* $OpenBSD: regs.c,v 1.8 2007/10/03 08:15:29 otto Exp $ */ /* * Copyright (c) 2005 Anders Magnusson (ragge@ludd.luth.se). * All rights reserved. @@ -30,6 +30,11 @@ #include <string.h> #include <stdint.h> #include <stdlib.h> +#include <string.h> +#ifdef HAVE_ALLOCA_H +#include <alloca.h> +#endif + #define MAXLOOP 20 /* Max number of allocation loops XXX 3 should be enough */ @@ -43,7 +48,7 @@ #define BIT2BYTE(bits) ((((bits)+NUMBITS-1)/NUMBITS)*(NUMBITS/8)) #define BITALLOC(ptr,all,sz) { \ - int __s = BIT2BYTE(sz); ptr = all(__s); memset(ptr, 0, __s); } + int sz__s = BIT2BYTE(sz); ptr = all(sz__s); memset(ptr, 0, sz__s); } #undef COMPERR_PERM_MOVE #define RDEBUG(x) if (rdebug) printf x |