Skip to content

Commit a6b04cf

Browse files
alimpfardawesomekling
authored andcommitted
LibProtocol: Ensure download is finished before invoking on_finished
1 parent a8ac8c6 commit a6b04cf

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Libraries/LibProtocol/Download.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ void Download::stream_into(OutputStream& stream)
6666
TODO();
6767
}
6868

69-
if (m_internal_stream_data->read_stream.eof() || (m_internal_stream_data->download_done && !m_internal_stream_data->success)) {
69+
if (m_internal_stream_data->read_stream.eof() && m_internal_stream_data->download_done) {
7070
m_internal_stream_data->read_notifier->close();
7171
user_on_finish(m_internal_stream_data->success, m_internal_stream_data->total_size);
7272
} else {

0 commit comments

Comments
 (0)