From 3146ff40901d034383911d3aeb6048eb141fa246 Mon Sep 17 00:00:00 2001 From: Alan Mishchenko Date: Fri, 13 Mar 2015 11:42:15 +0700 Subject: Fix incorrect transfer of box copy ID. --- src/misc/tim/timMan.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/misc/tim') diff --git a/src/misc/tim/timMan.c b/src/misc/tim/timMan.c index 43b2c6e7..5ffd71de 100644 --- a/src/misc/tim/timMan.c +++ b/src/misc/tim/timMan.c @@ -226,7 +226,7 @@ Tim_Man_t * Tim_ManTrim( Tim_Man_t * p, Vec_Int_t * vBoxPres ) if ( Vec_IntEntry(vBoxPres, i) ) { Tim_ManCreateBox( pNew, curPo, pBox->nInputs, curPi, pBox->nOutputs, pBox->iDelayTable ); - Tim_ManBoxSetCopy( pNew, Tim_ManBoxNum(pNew) - 1, i ); + Tim_ManBoxSetCopy( pNew, Tim_ManBoxNum(pNew) - 1, Tim_ManBoxCopy(p, i) == -1 ? i : Tim_ManBoxCopy(p, i) ); curPi += pBox->nOutputs; curPo += pBox->nInputs; } @@ -319,7 +319,7 @@ Tim_Man_t * Tim_ManReduce( Tim_Man_t * p, Vec_Int_t * vBoxesLeft, int nTermsDiff { pBox = Tim_ManBox( p, iBox ); Tim_ManCreateBox( pNew, curPo, pBox->nInputs, curPi, pBox->nOutputs, pBox->iDelayTable ); - Tim_ManBoxSetCopy( pNew, Tim_ManBoxNum(pNew) - 1, iBox ); + Tim_ManBoxSetCopy( pNew, Tim_ManBoxNum(pNew) - 1, Tim_ManBoxCopy(p, iBox) == -1 ? iBox : Tim_ManBoxCopy(p, iBox) ); curPi += pBox->nOutputs; curPo += pBox->nInputs; } -- cgit v1.2.3