Fixed that a stopped Download Kill the server.
This commit is contained in:
parent
fe883004f8
commit
bfd39d7558
1 changed files with 8 additions and 2 deletions
10
lweb.pbi
10
lweb.pbi
|
@ -1134,7 +1134,7 @@ Module lhs_web
|
|||
sent_total = thread_temp_file_readed+(thread_buffer_offset-thread_buffer)
|
||||
EndIf
|
||||
ldl::Logging("Memory send_total:"+Str(sent_total))
|
||||
;TODO: Stoped download kill server...
|
||||
;Erledigt: Stoped download kill server...
|
||||
If m_clients(Str(thread_cli_id))\client_type = #client_HTTPS
|
||||
sent_length = sent_total
|
||||
sent_buffer_address = thread_buffer
|
||||
|
@ -1181,7 +1181,13 @@ Module lhs_web
|
|||
sent_buffer_address = thread_buffer
|
||||
sent_total = 0
|
||||
Repeat
|
||||
sent = lsocket::WriteSocket(thread_cli_id, thread_buffer , sent_length)
|
||||
If lsocket::IsClientSocket(thread_cli_id)
|
||||
sent = lsocket::WriteSocket(thread_cli_id, thread_buffer , sent_length)
|
||||
Else
|
||||
thread_alive=#False
|
||||
Break 2
|
||||
EndIf
|
||||
|
||||
If sent <> -1
|
||||
ldl::Logging("HTTP Sent:"+Str(sent)+" bytes")
|
||||
sent_length - sent
|
||||
|
|
Loading…
Reference in a new issue