Fix *_ctx_new and *_ctx_free implementations
They both will only alloc and free the internal *_ctx structs. Get rid of the void * argument for new and only pass arg to *_free instead of the whole lc_*_ctx struct.
Dieser Commit ist enthalten in:
Ursprung
0a47025c19
Commit
f511cddf0d
6 geänderte Dateien mit 17 neuen und 18 gelöschten Zeilen
|
@ -154,11 +154,12 @@ poly1305_auth(const uint8_t *key, size_t keylen, uint8_t *out, size_t *outlen,
|
|||
}
|
||||
|
||||
static void *
|
||||
poly1305_ctx_new(const void *arg)
|
||||
poly1305_ctx_new(void)
|
||||
{
|
||||
return malloc(sizeof(struct poly1305_ctx));
|
||||
}
|
||||
|
||||
|
||||
static struct lc_auth_impl poly1305_impl = {
|
||||
.init = &poly1305_init,
|
||||
.update = &poly1305_update,
|
||||
|
|
Laden …
Tabelle hinzufügen
Einen Link hinzufügen
In neuem Issue referenzieren