Module Name: src
Committed By: joerg
Date: Fri Apr 12 18:12:16 UTC 2013
Modified Files:
src/gnu/dist/bc/bc: scan.l
Log Message:
yy_size_t is typically unsigned, so use a separate variable for the
return value of read(2).
To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/gnu/dist/bc/bc/scan.l
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/gnu/dist/bc/bc/scan.l
diff -u src/gnu/dist/bc/bc/scan.l:1.4 src/gnu/dist/bc/bc/scan.l:1.5
--- src/gnu/dist/bc/bc/scan.l:1.4 Thu Apr 11 19:00:41 2013
+++ src/gnu/dist/bc/bc/scan.l Fri Apr 12 18:12:15 2013
@@ -84,12 +84,14 @@ bcel_input (char *buf, yy_size_t *result
{
if (!edit || yyin != stdin)
{
- while ( (*result = read( fileno(yyin), buf, max )) < 0 )
+ ssize_t rv;
+ while ( (rv = read( fileno(yyin), buf, max )) < 0 )
if (errno != EINTR)
{
yyerror( "read() in flex scanner failed" );
exit (1);
}
+ *result = rv;
return;
}