X-Git-Url: https://git.distorted.org.uk/u/mdw/catacomb/blobdiff_plain/fe6657c961b01ec72e9f35f4c3d96b11b31cf09c..45c0fd363937c6e9b05da04a9167e9912c05ca0c:/g-ec.c diff --git a/g-ec.c b/g-ec.c index 0b55020..4679742 100644 --- a/g-ec.c +++ b/g-ec.c @@ -7,7 +7,7 @@ * (c) 2004 Straylight/Edgeware */ -/*----- Licensing notice --------------------------------------------------* +/*----- Licensing notice --------------------------------------------------* * * This file is part of Catacomb. * @@ -15,12 +15,12 @@ * it under the terms of the GNU Library General Public License as * published by the Free Software Foundation; either version 2 of the * License, or (at your option) any later version. - * + * * Catacomb is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU Library General Public License for more details. - * + * * You should have received a copy of the GNU Library General Public * License along with Catacomb; if not, write to the Free * Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, @@ -90,7 +90,7 @@ static void gexp(group *gg, ec *d, ec *x, mp *n) static void gmexp(group *gg, ec *d, const group_expfactor *f, size_t n) { gctx_ec *g = (gctx_ec *)gg; size_t i; - ec_mulfactor *ff = xmalloc(n * sizeof(ec_mulfactor)); + ec_mulfactor *ff = xmalloc(n * sizeof(ec_mulfactor)); for (i = 0; i < n; i++) { ff[i].base = *f[i].base; ff[i].exp = f[i].exp; } ec_immul(g->ei.c, d, ff, n); xfree(ff); } @@ -148,7 +148,7 @@ static int gfromec(group *gg, ec *d, const ec *x) { rc = EC_CHECK(g->ei.c, &t); if (!rc) EC_COPY(d, &t); EC_DESTROY(&t); return (rc); } - + static int gtobuf(group *gg, buf *b, ec *x) { gctx_ec *g = (gctx_ec *)gg; ec t = EC_INIT; int rc; EC_OUT(g->ei.c, &t, x); rc = buf_putec(b, &t); EC_DESTROY(&t); return (rc);