diff options
Diffstat (limited to 'src/ssl/rec_read.cpp')
-rw-r--r-- | src/ssl/rec_read.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/ssl/rec_read.cpp b/src/ssl/rec_read.cpp index 3c008641d..895026431 100644 --- a/src/ssl/rec_read.cpp +++ b/src/ssl/rec_read.cpp @@ -244,7 +244,9 @@ u32bit Record_Reader::get_record(byte& msg_type, throw TLS_Exception(BAD_RECORD_MAC, "Record_Reader: MAC failure"); msg_type = header[0]; - output.set(&plaintext[iv_size], plain_length); + + output.resize(plain_length); + copy_mem(&output[0], &plaintext[iv_size], plain_length); return 0; } |