Skip to content

Commit

Permalink
修复缓冲区存在空帧时无法拼接的问题
Browse files Browse the repository at this point in the history
  • Loading branch information
Vinlic committed Dec 5, 2023
1 parent f09677d commit eac1118
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/Synthesizer.js
Original file line number Diff line number Diff line change
Expand Up @@ -302,7 +302,7 @@ export default class Synthesizer extends EventEmitter {
if (!this.#pipeStream)
return;
if (this.#frameBufferIndex > 0)
this.#pipeStream.write(Buffer.concat(this.#frameBuffers));
this.#pipeStream.write(Buffer.concat(this.#frameBuffers.filter(v => v)));
this.#frameBufferIndex = 0;
if (!this.#pipeStream.closed)
this.#pipeStream.end();
Expand Down

0 comments on commit eac1118

Please sign in to comment.