diff options
Diffstat (limited to '')
-rw-r--r-- | src/number.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/number.cpp b/src/number.cpp index c23466e..be9b8be 100644 --- a/src/number.cpp +++ b/src/number.cpp | |||
@@ -483,9 +483,10 @@ void Number::divide( const Number &rhs, Number &q, Number &r ) const | |||
483 | for(; nNum.aInt[jtop] == 0; jtop++ ) { } | 483 | for(; nNum.aInt[jtop] == 0; jtop++ ) { } |
484 | // Bu::println("Computing remainder fraction from %1 to %2") | 484 | // Bu::println("Computing remainder fraction from %1 to %2") |
485 | // .arg( -iAnchor-1 ).arg( jtop ); | 485 | // .arg( -iAnchor-1 ).arg( jtop ); |
486 | r.aFrac.clear(); | ||
486 | for( int j = -iAnchor-1, k = 0; j >= jtop && k < r.iScale; j--, k++ ) | 487 | for( int j = -iAnchor-1, k = 0; j >= jtop && k < r.iScale; j--, k++ ) |
487 | { | 488 | { |
488 | if( j <= nNum.aInt.getSize() ) | 489 | if( j < nNum.aInt.getSize() ) |
489 | { | 490 | { |
490 | r.aFrac.set( k, nNum.aInt[j] ); | 491 | r.aFrac.set( k, nNum.aInt[j] ); |
491 | // Bu::println("setting %1 to %2").arg( k ).arg( nNum.aInt[j] ); | 492 | // Bu::println("setting %1 to %2").arg( k ).arg( nNum.aInt[j] ); |