Changeset 0848e34 for core/c


Ignore:
Timestamp:
Sep 24, 2015 10:13:33 PM (5 years ago)
Author:
dev <dev@…>
Branches:
master
Children:
73228a1
Parents:
5c56de7
Message:

Replaced 0 with NULL to fix miscompilation on windows.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • core/c/jbigi/jbigi/src/jbigi.c

    r5c56de7 r0848e34  
    103103        convert_j2mp(env, jexp,  &mexp);
    104104        if (mpz_sgn(mexp) < 0) {
    105             mpz_clears(mmod, mexp, 0);
     105            mpz_clears(mmod, mexp, NULL);
    106106            jclass exc = (*env)->FindClass(env, "java/lang/ArithmeticException");
    107107            (*env)->ThrowNew(env, exc, "Exponent cannot be negative");
     
    118118        convert_mp2j(env, mmod, &jresult);
    119119
    120         mpz_clears(mbase, mexp, mmod, 0);
     120        mpz_clears(mbase, mexp, mmod, NULL);
    121121
    122122        return jresult;
     
    171171        convert_j2mp(env, jexp,  &mexp);
    172172        if (mpz_sgn(mexp) <= 0) {
    173             mpz_clears(mmod, mexp, 0);
     173            mpz_clears(mmod, mexp, NULL);
    174174            jclass exc = (*env)->FindClass(env, "java/lang/ArithmeticException");
    175175            (*env)->ThrowNew(env, exc, "Exponent must be positive");
     
    183183        convert_mp2j(env, mmod, &jresult);
    184184
    185         mpz_clears(mbase, mexp, mmod, 0);
     185        mpz_clears(mbase, mexp, mmod, NULL);
    186186
    187187        return jresult;
     
    237237        mpz_gcd(mgcd, mbase, mmod);
    238238        if (mpz_cmp_si(mgcd, 1) != 0) {
    239             mpz_clears(mbase, mexp, mmod, mgcd, 0);
     239            mpz_clears(mbase, mexp, mmod, mgcd, NULL);
    240240            jclass exc = (*env)->FindClass(env, "java/lang/ArithmeticException");
    241241            (*env)->ThrowNew(env, exc, "Not coprime in nativeModInverse()");
     
    250250        convert_mp2j(env, mmod, &jresult);
    251251
    252         mpz_clears(mbase, mexp, mmod, mgcd, 0);
     252        mpz_clears(mbase, mexp, mmod, mgcd, NULL);
    253253
    254254        return jresult;
Note: See TracChangeset for help on using the changeset viewer.