Quick Search:

Mode

Context

Displaying 3 lines of context. None | Less | More | Full

Other Diffs

Ignore

Blank Lines Whitespace: Expand:

Diff

1.80
 
1.81
 
MAIN:ragge:20030706141912
 
pftn.c
_>66 
 77 # include <stdlib.h>
 88 
<>9 -unsigned int offsz;
 10 -
119 struct symtab *spname;
 1210 struct symtab *cftnsp;
 1311 static int strunem;             /* currently parsed member type */
     
 !
15331531 
 15341532         off = *poff;
 15351533         SETOFF(off, alignment);
<>1536 -        if ((offsz-off)size) {      /* XXX 4.4 */
 1537 -                if (instruct != INSTRUCT)
 1538 -                        cerror("too many local variables");
 1539 -                else
 1540 -                        cerror("Structure too large");
 1541 -        }
  1534+        if (off < 0)
  1535+                cerror("structure or stack overgrown"); /* wrapped */
15421536         *poff = off+size;
 15431537         return (off);
 15441538 }
     
 !
15571551         tsz = tsize(p->stype, p->sdf, p->ssue);
 15581552 #ifdef BACKAUTO
 15591553         if (p->sclass == AUTO) {
<>1560 -                if ((offsz-off) < tsz)  /* XXX 4.4 */
 1561 -                        cerror("too many local variables");
15621554                 noff = off + tsz;
<> 1555+                if (noff < 0)
  1556+                        cerror("stack overflow");
15631557                 SETOFF(noff, al);
 15641558                 off = -noff;
 15651559         } else
 15661560 #endif
 15671561 #ifdef PARAMS_UPWARD
 15681562         if (p->sclass == PARAM) {
<>1569 -                if ((offsz-off) < tsz)
 1570 -                        cerror("too many parameters");
15711563                 noff = off + tsz;
<> 1564+                if (noff < 0)
  1565+                        cerror("too many parameters");
15721566                 if (tsz < SZINT)
 15731567                         al = ALINT;
 15741568                 SETOFF(noff, al);
 15751569                 off = -noff;
 15761570 
 15771571         } else
 15781572 #endif
<>1579 -        if (p->sclass == PARAM && (tsz < SZINT)) {      /* XXX 4.4 */
  1573+        if (p->sclass == PARAM && (p->stype == CHAR || p->stype == UCHAR ||
  1574+            p->stype == SHORT || p->stype == USHORT)) {
15801575                 off = upoff(SZINT, ALINT, &noff);
 15811576 #ifndef RTOLBYTES
 15821577                 off = noff - tsz;
     
 !
17421737 
 17431738         if( strucoff%al + w > sz ) SETOFF( strucoff, al );
 17441739         if( new < 0 ) {
<>1745 -                if( (offsz-strucoff) < w )      /* XXX 4.4 */
 1746 -                        cerror("structure too large");
17471740                 strucoff += w/* we know it will fit */
 17481741                 return(0);
 17491742                 }
     
 !
17541747                 if( p->soffset != strucoff || p->sclass != (FIELD|w) ) return(1);
 17551748                 }
 17561749         p->soffset = strucoff;
<>1757 -        if( (offsz-strucoff) < w ) cerror("structure too large");
<_17581750         strucoff += w;
 17591751         p->stype = type;
 17601752         fldty( p );
FishEye: Open Source License registered to PCC.
Your maintenance has expired. You can renew your license at http://www.atlassian.com/fisheye/renew
Atlassian FishEye, CVS analysis. (Version:1.6.3 Build:build-336 2008-11-04) - Administration - Page generated 2014-10-31 14:33 +0100