Skip to content

Commit 28a8df1

Browse files
committed
StreamCopyT avoid delete
1 parent 9d3e581 commit 28a8df1

File tree

1 file changed

+0
-6
lines changed

1 file changed

+0
-6
lines changed

src/AudioTools/CoreAudio/StreamCopy.h

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -59,17 +59,12 @@ class StreamCopyT {
5959

6060
/// Ends the processing
6161
void end() {
62-
if (is_cleanup_from) {
63-
delete this->from;
64-
is_cleanup_from = false;
65-
}
6662
this->from = nullptr;
6763
this->to = nullptr;
6864
}
6965

7066
/// assign a new output and input stream
7167
void begin(Print &to, Stream &from){
72-
is_cleanup_from = true;
7368
this->from = &from;
7469
this->to = &to;
7570
begin();
@@ -368,7 +363,6 @@ class StreamCopyT {
368363
int (*availableCallback)(Stream*stream)=nullptr;
369364
void *onWriteObj = nullptr;
370365
bool is_first = false;
371-
bool is_cleanup_from = false;
372366
bool check_available_for_write = false;
373367
bool check_available = true;
374368
const char* actual_mime = nullptr;

0 commit comments

Comments
 (0)