Quick Search:

Mode

Context

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

Other Diffs

Ignore

Blank Lines Whitespace: Expand:

Diff

1.62
 
1.63
 
MAIN:ragge:20070920202757
 
cpp.c
_>427427                 llen = c;
 428428         }
 429429         yytext[strlen(yytext)-1] = 0;
<>430 -        strcpy((char *)lbuf, &yytext[1]);
  430+        if (strlcpy((char *)lbuf, &yytext[1], SBSIZE) >= SBSIZE)
  431+                error("line exceeded buffer size");
  432+
431433         ifiles->fname = lbuf;
 432434         if (yylex() != '\n')
 433435                 goto bad;
     
 !
549551         int c, i, redef;
 550552         int mkstr = 0, narg = -1;
 551553         int ellips = 0;
<> 554+        int len;
552555 
 553556         if (flslvl)
 554557                 return;
     
 !
577580                                 break;
 578581                         }
 579582                         if (c == IDENT) {
<>580 -                                args[narg] = alloca(strlen(yytext)+1);
 581 -                                strcpy((char *)args[narg], yytext);
  583+                                len = strlen(yytext);
  584+                                args[narg] = alloca(len+1);
  585+                                strlcpy((char *)args[narg], yytext, len+1);
582586                                 narg++;
 583587                                 if ((c = definp()) == ',')
 584588                                         continue;
     
 !
947951                         stksv = NULL;
 948952                         if ((c = yylex()) == WSPACE) {
 949953                                 stksv = alloca(yyleng+1);
<>950 -                                strcpy((char *)stksv, yytext);
  954+                                strlcpy((char *)stksv, yytext, yyleng+1);
<_951955                                 c = yylex();
 952956                         }
 953957                         /* only valid for expansion if fun macro */
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-09-19 17:52 +0200