X-Git-Url: https://git.distorted.org.uk/u/mdw/catacomb/blobdiff_plain/ae747c9bab929bc794ddad9f59c381657d347d1f..3563e36580c7dad68cd6d3f7eb82eef570fc0c76:/gfx-sqr.c diff --git a/gfx-sqr.c b/gfx-sqr.c index b253a32..60e1b3c 100644 --- a/gfx-sqr.c +++ b/gfx-sqr.c @@ -1,6 +1,6 @@ /* -*-c-*- * - * $Id: gfx-sqr.c,v 1.1 2000/10/08 15:49:37 mdw Exp $ + * $Id: gfx-sqr.c,v 1.3 2004/04/02 01:03:49 mdw Exp $ * * Sqaring binary polynomials * @@ -30,6 +30,15 @@ /*----- Revision history --------------------------------------------------* * * $Log: gfx-sqr.c,v $ + * Revision 1.3 2004/04/02 01:03:49 mdw + * Miscellaneous constification. + * + * Revision 1.2 2004/03/21 22:52:06 mdw + * Merge and close elliptic curve branch. + * + * Revision 1.1.4.1 2004/03/21 22:39:46 mdw + * Elliptic curves on binary fields work. + * * Revision 1.1 2000/10/08 15:49:37 mdw * First glimmerings of binary polynomial arithmetic. * @@ -38,12 +47,12 @@ /*----- Header files ------------------------------------------------------*/ #include "mpx.h" -/* #include "gfx.h" */ +#include "gfx.h" #include "gfx-sqr-tab.h" /*----- Static variables --------------------------------------------------*/ -static uint16 tab[256] = GFX_SQRTAB; +static const uint16 tab[256] = GFX_SQRTAB; /*----- Main code ---------------------------------------------------------*/ @@ -99,7 +108,7 @@ void gfx_sqr(mpw *dv, mpw *dvl, const mpw *av, const mpw *avl) /* --- Output buffering --- */ - if (bb > MPW_BITS) { + if (bb >= MPW_BITS) { *dv++ = MPW(aa); if (dv >= dvl) return;