Update the index into a partial Poly1305 buffer instead of overwriting

This commit is contained in:
Dom Crossley 2016-12-07 09:33:55 +00:00
parent 88e614b675
commit a251c9ff15

View File

@ -132,7 +132,7 @@ void cryptonite_poly1305_update(poly1305_ctx *ctx, uint8_t *data, uint32_t lengt
/* fill the remaining bytes in the partial buffer */
if (length) {
memcpy(ctx->buf + ctx->index, data, length);
ctx->index = length;
ctx->index += length;
}
}