new batch of delete operator missmatch

This commit is contained in:
Nikita Edel
2026-03-09 22:48:36 +01:00
parent 10ee2085ff
commit 66b31669c3
13 changed files with 27 additions and 17 deletions

View File

@@ -15,7 +15,11 @@ BufferedOutputStream::BufferedOutputStream(OutputStream *out, int size)
BufferedOutputStream::~BufferedOutputStream()
{
delete buf.data;
//4jcraft, changed to [], deallocates internal buffer
//TODO: ArrayWithLength.h doesnt have a destructor.
//this wouldnt need to be done manually.
//but for some reason the destructor is commented out in the source code?
delete[] buf.data;
}
//Flushes this buffered output stream. This forces any buffered output bytes to be written out to the underlying output stream.