summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlan Mishchenko <alanmi@berkeley.edu>2012-07-29 22:36:21 -0700
committerAlan Mishchenko <alanmi@berkeley.edu>2012-07-29 22:36:21 -0700
commit216fc33a47e357c3727aae8e980a0031bb8fbde1 (patch)
tree46ca0c03add8829e04f3b33e6d877417b803ecc5
parent8982bf58cb8c801bdd6e204d73ac6ed36d98adaa (diff)
downloadabc-216fc33a47e357c3727aae8e980a0031bb8fbde1.tar.gz
abc-216fc33a47e357c3727aae8e980a0031bb8fbde1.tar.bz2
abc-216fc33a47e357c3727aae8e980a0031bb8fbde1.zip
Fixed compiler warnings.
-rw-r--r--src/base/abci/abcDec.c4
-rw-r--r--src/sat/bsat/satUtil.c4
2 files changed, 4 insertions, 4 deletions
diff --git a/src/base/abci/abcDec.c b/src/base/abci/abcDec.c
index 8f0d1df8..8fce068d 100644
--- a/src/base/abci/abcDec.c
+++ b/src/base/abci/abcDec.c
@@ -176,7 +176,7 @@ char * Abc_FileRead( char * pFileName )
{
FILE * pFile;
char * pBuffer;
- int nFileSize;
+ int nFileSize, RetValue;
pFile = fopen( pFileName, "rb" );
if ( pFile == NULL )
{
@@ -190,7 +190,7 @@ char * Abc_FileRead( char * pFileName )
rewind( pFile );
// load the contents of the file into memory
pBuffer = (char *)malloc( nFileSize + 3 );
- fread( pBuffer, nFileSize, 1, pFile );
+ RetValue = fread( pBuffer, nFileSize, 1, pFile );
// add several empty lines at the end
// (these will be used to signal the end of parsing)
pBuffer[ nFileSize + 0] = '\n';
diff --git a/src/sat/bsat/satUtil.c b/src/sat/bsat/satUtil.c
index abd668c6..59eb047d 100644
--- a/src/sat/bsat/satUtil.c
+++ b/src/sat/bsat/satUtil.c
@@ -89,7 +89,7 @@ void Sat_SolverWriteDimacs( sat_solver * p, char * pFileName, lit* assumpBegin,
return;
}
// fprintf( pFile, "c CNF generated by ABC on %s\n", Extra_TimeStamp() );
- fprintf( pFile, "p cnf %d %d\n", p->size, Sat_MemEntryNum(&p->Mem, 0)+Sat_MemEntryNum(&p->Mem, 1)+nUnits+(assumpEnd-assumpBegin) );
+ fprintf( pFile, "p cnf %d %d\n", p->size, Sat_MemEntryNum(&p->Mem, 0)+Sat_MemEntryNum(&p->Mem, 1)+nUnits+(int)(assumpEnd-assumpBegin) );
// write the original clauses
Sat_MemForEachClause( pMem, c, i, k )
@@ -141,7 +141,7 @@ void Sat_Solver2WriteDimacs( sat_solver2 * p, char * pFileName, lit* assumpBegin
return;
}
// fprintf( pFile, "c CNF generated by ABC on %s\n", Extra_TimeStamp() );
- fprintf( pFile, "p cnf %d %d\n", p->size, Sat_MemEntryNum(&p->Mem, 0)+Sat_MemEntryNum(&p->Mem, 1)+nUnits+(assumpEnd-assumpBegin) );
+ fprintf( pFile, "p cnf %d %d\n", p->size, Sat_MemEntryNum(&p->Mem, 0)+Sat_MemEntryNum(&p->Mem, 1)+nUnits+(int)(assumpEnd-assumpBegin) );
// write the original clauses
Sat_MemForEachClause2( pMem, c, i, k )