summaryrefslogtreecommitdiffstats
path: root/src/base/io/ioWriteAiger.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/base/io/ioWriteAiger.c')
-rw-r--r--src/base/io/ioWriteAiger.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/src/base/io/ioWriteAiger.c b/src/base/io/ioWriteAiger.c
index 54db0641..3900cf26 100644
--- a/src/base/io/ioWriteAiger.c
+++ b/src/base/io/ioWriteAiger.c
@@ -21,12 +21,16 @@
// The code in this file is developed in collaboration with Mark Jarvin of Toronto.
+#include "bzlib.h"
#include "ioAbc.h"
#include <stdarg.h>
-#include "bzlib.h"
#include "zlib.h"
+
+ABC_NAMESPACE_IMPL_START
+
+
#ifdef _WIN32
#define vsnprintf _vsnprintf
#endif
@@ -137,7 +141,7 @@ Binary Format Definition
static unsigned Io_ObjMakeLit( int Var, int fCompl ) { return (Var << 1) | fCompl; }
static unsigned Io_ObjAigerNum( Abc_Obj_t * pObj ) { return (unsigned)(ABC_PTRINT_T)pObj->pCopy; }
-static void Io_ObjSetAigerNum( Abc_Obj_t * pObj, unsigned Num ) { pObj->pCopy = (void *)(ABC_PTRINT_T)Num; }
+static void Io_ObjSetAigerNum( Abc_Obj_t * pObj, unsigned Num ) { pObj->pCopy = (Abc_Obj_t *)(ABC_PTRINT_T)Num; }
////////////////////////////////////////////////////////////////////////
/// FUNCTION DEFINITIONS ///
@@ -451,7 +455,7 @@ void Io_WriteAigerGz( Abc_Ntk_t * pNtk, char * pFileName, int fWriteSymbols )
// write the nodes into the buffer
Pos = 0;
nBufferSize = 6 * Abc_NtkNodeNum(pNtk) + 100; // skeptically assuming 3 chars per one AIG edge
- pBuffer = ABC_ALLOC( char, nBufferSize );
+ pBuffer = ABC_ALLOC( unsigned char, nBufferSize );
pProgress = Extra_ProgressBarStart( stdout, Abc_NtkObjNumMax(pNtk) );
Abc_AigForEachAnd( pNtk, pObj, i )
{
@@ -751,3 +755,5 @@ void Io_WriteAiger( Abc_Ntk_t * pNtk, char * pFileName, int fWriteSymbols, int f
////////////////////////////////////////////////////////////////////////
+ABC_NAMESPACE_IMPL_END
+