/* -*-c-*-
*
- * $Id: gfx-sqr.c,v 1.1 2000/10/08 15:49:37 mdw Exp $
+ * $Id$
*
* Sqaring binary polynomials
*
* MA 02111-1307, USA.
*/
-/*----- Revision history --------------------------------------------------*
- *
- * $Log: gfx-sqr.c,v $
- * Revision 1.1 2000/10/08 15:49:37 mdw
- * First glimmerings of binary polynomial arithmetic.
- *
- */
-
/*----- 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 ---------------------------------------------------------*/
/* --- Output buffering --- */
- if (bb > MPW_BITS) {
+ if (bb >= MPW_BITS) {
*dv++ = MPW(aa);
if (dv >= dvl)
return;
ok = 0;
}
- free(a); free(b); free(d);
+ xfree(a); xfree(b); xfree(d);
return (ok);
}