math/mpgen: Fix bugs in slot handling.
authorMark Wooding <mdw@distorted.org.uk>
Wed, 14 May 2014 20:29:29 +0000 (21:29 +0100)
committerMark Wooding <mdw@distorted.org.uk>
Wed, 14 May 2014 20:36:18 +0000 (21:36 +0100)
commit18533217a1622569aa813252fceef43bae9276e7
tree91b3639b610b36ceff8a31a23b27766bebfe7c1e
parente51127d5563060b2bcf586a4a9ed0080954a59cf
math/mpgen: Fix bugs in slot handling.

Several bugs, which conspired to cover their tracks.

  * BaseSlot never actually stored the `omitp' and `allowp' functions.

  * The MPSlot handler didn't chain up to the BaseSlot implementation
    of `setup'.

  * The EllipticCurveGroup's `beta' slot definition's `omitp' and `allowp'
    functions used the slot name `type' instead of the object.

The incorrect lookups were hidden because the functions were never called.
The omission of `beta' values for most curve groups should then have
caused an error, only MPSlot.setup didn't chain up to the method which
would have noticed.
math/mpgen