Merge pull request #390 from hamishcoleman/leakfix

Avoid leaking memory if the buffer is uncompressable
This commit is contained in:
Luca Deri 2020-08-28 13:03:29 +02:00 committed by GitHub
commit 3c98328618
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1488,6 +1488,9 @@ void edge_send_packet2net(n2n_edge_t * eee,
memcpy (tap_pkt, compression_buffer, compression_len);
len = compression_len;
}
if(compression_buffer) {
free (compression_buffer);
}
}