Opened 6 years ago

Closed 6 years ago

Last modified 5 years ago

#14598 closed defect (fixed)

wxHTTP doesn't block when sending big POST data

Reported by: Platonides Owned by:
Priority: normal Milestone:
Component: wxGTK Version:
Keywords: Cc:
Blocked By: Blocking:
Patch: yes


I am POSTing files from a secondary thread and noticed that it didn't send the full data.
wxWidgets tried to post the full file, the send() syscall only partially accepted it and wxWidgets never passing them again. The webserver keeps waiting (due to the Content-Length being right) and finally the connection timeouts.

Simply adding wxSOCKET_WAITALL flag to the socket fixed it (src/common/http.c:391).

Attachments (1)

wxWidgets-wxHttp.patch download (626 bytes) - added by Platonides 6 years ago.
wxHTTP patch

Download all attachments as: .zip

Change History (4)

Changed 6 years ago by Platonides

wxHTTP patch

comment:1 Changed 6 years ago by VZ

  • Resolution set to fixed
  • Status changed from new to closed

(In [72409]) Use wxSOCKET_WAITALL in wxHTTP to ensure that all data is sent.

POST-ing sufficiently big amounts of data in wxHTTP didn't work because it
couldn't be sent all at once to the server. Use wxSOCKET_WAITALL to ensure
that we do send all of the data.

Closes #14598.

comment:2 Changed 5 years ago by VZ

(In [73391]) Set margins on creation correctly for wxTE_RICH[2] wxTextCtrl in wxMSW.

In spite of the MSDN documentation, EC_USEFONTINFO can't be used in lParam
with rich edit controls, so pass it in wParam for them.

Closes #14598.

comment:3 Changed 5 years ago by vadz

Sorry, disregard last comment, wrong ticket number (was supposed to be #14958).

Note: See TracTickets for help on using tickets.