Changeset 19ee5eb in git for libpolys/coeffs/rmodulo2m.cc


Ignore:
Timestamp:
Feb 1, 2021, 1:32:52 PM (3 years ago)
Author:
Hans Schoenemann <hannes@…>
Branches:
(u'spielwiese', '17f1d200f27c5bd38f5dfc6e8a0879242279d1d8')
Children:
4218c13e2434358d0a056b78d0a40377a11bcdb1
Parents:
f60ab1f6c47a09dc3472f9d3cabd270622c46327
Message:
fix: division by 0: return 0, not NULL
File:
1 edited

Legend:

Unmodified
Added
Removed
  • libpolys/coeffs/rmodulo2m.cc

    rf60ab1 r19ee5eb  
    412412      }
    413413    }
    414     if ((unsigned long)b % 2 == 0)
     414    if ((long)b==0L)
     415    {
     416      WerrorS(nDivBy0);
     417      return (number)0L;
     418    }
     419    else if ((unsigned long)b % 2 == 0)
    415420    {
    416421      WerrorS("Division not possible, even by cancelling zero divisors.");
Note: See TracChangeset for help on using the changeset viewer.