summaryrefslogtreecommitdiffstats
path: root/src/network/access/qnetworkreplywasmimpl.cpp
Commit message (Collapse)AuthorAgeFilesLines
* wasm: fix network status code propagationLorn Potter2020-09-251-6/+13
| | | | | | | | Fixes: QTBUG-86620 Pick-to: 5.15 Change-Id: I911636739dc57e47bc2a07a583f4e67fc08b1b19 Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io> Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* wasm: fix setTransferTimeoutLorn Potter2020-07-291-1/+1
| | | | | | | | | | WebAssembly does not need the http feature, but these functions were hidden behind that feature. Fixes: QTBUG-83867 Pick-to: 5.15 Change-Id: I7cd9aa73003f45ccbc2613c67c21e4067d6edddd Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* wasm: fix network headers logicLorn Potter2020-07-291-6/+8
| | | | | | | Fixes: QTBUG-85083 Pick-to: 5.15 Change-Id: Iaf0f3365ee20fe257f3edac0e1105bdfcc5ba0da Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* wasm: do not close QIODevice on errorLorn Potter2020-06-291-3/+0
| | | | | | | | | | | Closing it early means the user may get this message when reading data without checking for error: 'QIODevice::read (QNetworkReplyWasmImpl): device not open' Change-Id: I377fc3da68e9d9f14f8504ace5addbb4f8e3c539 Fixes: QTBUG-85176 Pick-to: 5.15 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* wasm: fix crash when getting error like 404Lorn Potter2020-06-201-1/+0
| | | | | | Pick-to: 5.15 Change-Id: Ia9b81aaa8b1e9ea6ab20b8c6ff6f197e95d46d7d Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* wasm: fix network reply timeout and error handlingLorn Potter2020-06-191-12/+21
| | | | | | | | Fixes: QTBUG-83728 Change-Id: Ib8184a497a028949eea20e9d189d79da51ccc290 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io> (cherry picked from commit b2e998d4678b82f823d24f3c97d78dec034f4e71) Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* wasm: fix network POST data corruptionLorn Potter2020-06-111-5/+4
| | | | | | | | | | Emscripten does not like when the post data gets deleted in the local scope. Fixes: QTBUG-84685 Pick-to: 5.15 Change-Id: I17f9d5cc3253c26b42253daa68e2fbaccc48eaf6 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* QtNetwork remove deprecated signalsTimur Pocheptsov2020-06-041-1/+1
| | | | | | | | | | Use 'errorOccurred' instead of 'error' and 'sslHandshakeErrors' instead of 'sslErrors'. Fixes: QTBUG-82605 Change-Id: I19d4845b16c7b636af7b0658d4fbbba4eef9d029 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
* wasm: set status codes from network operationLorn Potter2020-05-251-9/+18
| | | | | | | Pick-to: 5.15 Fixes: QTBUG-83991 Change-Id: Ie1e88189bee8b6a9dc6cb2a721777a5e1032307a Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* wasm: fix heap crash when making multiple network callsLorn Potter2020-05-251-19/+22
| | | | | | | Pick-to: 5.15 Task-number: QTBUG-83991 Change-Id: I354934b53799f3eeb958395932bed18289b1e279 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* wasm: fix network download crashLorn Potter2020-04-291-1/+1
| | | | | | | | It seems it was defaulting to the indexdb filesystem, but it is not mounted. Fixes: QTBUG-83827 Change-Id: I1f81d790e5786fe41b59c0f41ca7f6025732c9b2 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* wasm: refactor network to use fetch APILorn Potter2020-03-261-201/+110
| | | | | | | | | | This has better support for threaded use, and gets rid of bind use. This requires emscripten 1.38.37 and above Task-number: QTBUG-76891 Change-Id: Ic30a6820c2ce945c314751c06cfc356914a71217 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* Use Qt::SplitBehavior in preference to QString::SplitBehaviorEdward Welbourne2020-02-281-1/+1
| | | | | | | | The Qt version was added in 5.14 "for use as eventual replacement for QString::SplitBehavior." Move another step closer to that goal. Change-Id: I399b5ea56e9255e775ca1746632f7421519a6616 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* wasm: add network object checkingLorn Potter2019-08-231-0/+18
| | | | | | | | This should help when things are moving fast, and downloads and network object are destroyed before the callbacks finishes. Change-Id: I1f65965bd61efc2e641d03eb071f23e684dd5c44 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* wasm: fix wide character data downloadLorn Potter2019-07-291-2/+4
| | | | | | | | Need to pass correct buffer size Change-Id: I19cb65114f49decc225cd807d59f1f08ad6b70c9 Fixes: QTBUG-76212 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* Add custom verb support for WASM HTTP requestsFelix Barz2019-07-031-0/+3
| | | | | | | | | | | | | The QNetworkReply implementation for Qt for WebAssembly now supports usage of the QNetworkAccessManager::sendCustomRequest, making it possible to send requests with custom verbs. [ChangeLog][QtNetwork][QNetworkAccessManager] Fixed QNetworkAccessManager::sendCustomRequest for Qt For WebAssembly. Fixes: QTBUG-76775 Change-Id: I9394ffef110fce4ed2c877893631bedc7631f71e Reviewed-by: Lorn Potter <lorn.potter@gmail.com>
* wasm: fix crash in case network js event becomes null or undefinedLorn Potter2019-05-271-10/+43
| | | | | | | | | | | also fix data progress Task-number: QTBUG-75489 Change-Id: I5222fda64d258a6ae78ba0ca20194b81c289c27e Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* wasm: fix empty body on POSTLorn Potter2019-05-221-26/+6
| | | | | | | | this also optimizes network post method handling Task-number: QTBUG-75660 Change-Id: Ibb0d01f2cc2b2bc7802598c4f6f04b04882c12ca Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* wasm: Use common “qt” prefix for exported functionsMorten Johan Sørvig2019-03-261-11/+11
| | | | | | | | Prevent namespace collisions and make sure Qt functions are grouped together. Change-Id: I217188ee93e4300e273d10a79d6014179fc5a1ef Reviewed-by: Lorn Potter <lorn.potter@gmail.com>
* wasm: fix error report when network request is cancelledv5.13.0-beta1Lorn Potter2019-03-111-0/+1
| | | | | | Fixes: QTBUG-73346 Change-Id: I8aaf8fe45f3014e2c9187c554ed86a4d29c03c0b Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* wasm: fix corrupt downloadsLorn Potter2019-03-041-1/+1
| | | | | | | | | | This would only ever put the first 16k into the buffer that gets read, so this 16k would get repeated until the size of the download. Task-number: QTBUG-74123 Change-Id: Ia53bedf6a8754d9fd83fd0ab62866cfa5af5cc1a Reviewed-by: Mikhail Svetkin <mikhail.svetkin@qt.io> Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* wasm: fix blob download handlingLorn Potter2019-01-091-11/+16
| | | | | | Change-Id: I34a8ec05c18b15ed71787986b5b0316693235b4d Fixes: QTBUG-72105 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* wasm: emit finished after QNetworkReply abortLorn Potter2018-12-181-10/+21
| | | | | | Change-Id: I23445f5e0c936b82aa5d65b261d456a563deab9a Fixes: QTBUG-72516 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* wasm: do not revise url of queriesLorn Potter2018-12-161-9/+1
| | | | | | | | | | | I think this may have been for some POST method form queries, but obviously was missing something. Task-number: QTBUG-72382 Change-Id: I59016776aeedf4b5599b3b44af70610babb0a61e Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io> Reviewed-by: Ryan Chu <ryan.chu@qt.io>
* wasm: rewrite QNetworkReplyWasmImpl to remove EM_ASMLorn Potter2018-10-091-202/+180
| | | | | | | | | and fix handling of incoming binary data Change-Id: I31e97505ad4ff64cf8e380df5d0d6b70c3cd60b0 Reviewed-by: Ryan Chu <ryan.chu@qt.io> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* WebAssembly for QtBaseMorten Johan Sørvig2018-08-301-0/+640
This is the squashed diff from wip/webassembly to dev. Done-with: Peng Wu <peng.wu@intopalo.com> Done-with: Sami Enne <sami.enne@intopalo.com> Done-with: Morten Johan Sørvig <morten.sorvig@qt.io> Started-by: Andrew Knight <andrew.knight@intopalo.com> Change-Id: I6562433c0a38d6ec49ab675e0f104f2665f3392d Reviewed-by: Lorn Potter <lorn.potter@gmail.com> Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>