summaryrefslogtreecommitdiff
path: root/dmake
diff options
context:
space:
mode:
authorPierre-André Jacquod <pjacquod@alumni.ethz.ch>2011-10-03 12:47:16 +0200
committerPierre-André Jacquod <pjacquod@alumni.ethz.ch>2011-10-07 15:57:52 +0200
commit8fc65666ea32241f192eda8f8e4eb11e90c5fca3 (patch)
tree029e5c8cd7684e80494d4cd0efceab774ca152d0 /dmake
parent2b6ef29f451c707c151025b85e87196c3602b44e (diff)
cppcheck scope reduction in dmake/getinp.c
Diffstat (limited to 'dmake')
-rw-r--r--dmake/getinp.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/dmake/getinp.c b/dmake/getinp.c
index 1ac312a53b59..419e62506966 100644
--- a/dmake/getinp.c
+++ b/dmake/getinp.c
@@ -731,7 +731,6 @@ int partcomp( char* lhs, int opcode )
int result, opsind;
const int localopscount=4;
char* localops[] = { "==", "!=", "<=", ">=" };
- int lint, rint;
#define EQUAL 0
#define NOTEQUAL 1
@@ -817,8 +816,8 @@ int partcomp( char* lhs, int opcode )
if ( rhs && rhs[0] == '"' ) rhs++;
/* Empty strings evaluate to zero. */
- lint = lhs ? atoi( lhs ) : 0;
- rint = rhs ? atoi( rhs ) : 0;
+ int lint = lhs ? atoi( lhs ) : 0;
+ int rint = rhs ? atoi( rhs ) : 0;
result = ( lint >= rint ) ? TRUE : FALSE;
if ( opsind == LESS_EQUAL && lint != rint )
result = !result;