aboutsummaryrefslogtreecommitdiff
path: root/backends/networking
AgeCommit message (Collapse)Author
2019-11-05NETWORKING: Fix compilation for lower versions of libcurlEugene Sandulenko
2019-11-05NETWORKING: Enter SessionAlexander Tkachev
Session allows to reuse SessionRequests to the same host by making them keeping alive connection. Turns out, though, that libcurl already does that for us, and we didn't gain any speedup we thought we'd get. Usage: ``` Networking::Session s; Networking::SessionRequest *request = s.get(url); request->startAndWait(); warning("HTTP GET: %s", request->text()); s.close(); ``` You can still use SessionRequest without Session (but you can't put them on stack!): ``` Networking::SessionRequest *request = new Networking::SessionRequest(url); request->startAndWait(); warning("HTTP GET: %s", request->text()); request->close(); ```
2019-11-05NETWORKING: Enter SessionRequestAlexander Tkachev
It is to be used in a Session, though it might be used separately. It must implement keep-alive, but it does not yet. You must not put it to ConnMan by yourself (instead, use start()) and you must call close() after you've finished using this request. You can either work with it in callback, or wait() and simply use its methods (check it's success() and then, for example, use text()). Like this: ``` Networking::SessionRequest *rq = new Networking::SessionRequest(url); rq->startAndWait(); if (rq->success()) warning("HTTP GET: %s", rq->text()); rq->close(); ```
2019-11-05NETWORKING: Add CurlRequest::wait()Alexander Tkachev
2019-11-05JANITORIAL: Fix Networking::DataResponse typedef namingAlexander Tkachev
2019-11-03NETWORKING: Try loading the CA bundle from DATA_PATHBastien Bouclet
2019-11-03NETWORKING: Improve libcurl error handlingBastien Bouclet
Error messages for failed requests are now printed as warnings.
2019-11-01ANDROID: Disable verification of certificates validity for cloud savingThanasis Antoniou
Also added macros for the plain (non-SDL) Android port __ANDROID_PLAIN_PORT__ and ANDROID_PLAIN_PORT The workaround of this commit uses the same logic as for the Nintendo Switch port and should suffice for testing purposes. It should be replaced by more elaborate code of installing and maintaining a certificates pem file.
2019-10-25NETWORKING: Remove unnesessary checkEugene Sandulenko
2019-10-24NETWORKING: Reworked PostRequest to a more universal APIEugene Sandulenko
2019-10-24NETWORKING: Changed PostRequest to accept JSONValueEugene Sandulenko
2019-10-24NETWORKING: Added simple request handlerEugene Sandulenko
2019-10-13SWITCH: Fix cloud integrationrsn8887
2019-10-05NETWORKING: Fix Signed vs. Unsigned Compiler WarningsD G Turner
2019-09-21NETWORKING: Convert translation results to UTF-8 for local webserver pagesThierry Crozat
2019-09-14NETWORKING: Clarify where to put wwwroot.zipEugene Sandulenko
2019-09-14NETWORKING: Clarify message when web server resources are not availableEugene Sandulenko
2019-08-25CLOUD: Make Network::ErrorResponse messages more verboseAlexander Tkachev
This commit updates all usages of Network::ErrorResponse to specify at least method name if not precise reason why operation failed.
2019-08-25CLOUD: Handle HTTP response headers case-insensitivelyAlexander Tkachev
RFC 2616 states that HTTP headers are not case-sensitive and also allows arbitrary number of whitespace characters around header value. Previous implementation was dependant on headers to be in "Title-Case" and to have only one space before header value. That has lead to cloud sync failure on Debian x64 (user's network environment was probably the reason though). This commit adds a new method, which parses headers name-value pairs into HashMap. To ensure case-insensitivity, all headers names are converted to lowercase, and thus code that uses this method should specify headers in lowercase. All usages of raw headers contents were updated to use this method.
2019-08-06BACKENDS: Rename and simplify AbstractFSNode::create()Cameron Cawley
2019-07-30GUI: Rewrite Cloud tabAlexander Tkachev
- StorageWizardDialog is removed, along with bmps it was using; - EditTextWidget now accepts custom font in constructor; - ScrollContainer scrollbar now jumps to top when content height changes so it's "overscrolled"; - IndexPageHandler now does not awaits for `code` GET-parameter, as local webserver is no longer used to connect Storages; - CloudManager and all corresponding Storages are updated to support disconnecting and to notify about successful connection.
2019-07-30CLOUD: Handle Cloud requests more frequentlyAlexander Tkachev
ConnectionManager used to poll Cloud requests every second, while curl requests were polled every 1/20th of a second. If curl request was over at, say, frame #21, corresponding Cloud request would've only work with that at frame #40 (950 ms later), which was making everything cloud-related slower than it could be. This commit fixes it by making Cloud polling period the same as curl polling period, and additionally raises FPS to 25.
2019-06-21ANDROID: Move isConnectionLimited into OSystemCameron Cawley
2018-12-17WIN32: Fix libcurl redefining ARRAYSIZESupSuper
libcurl pulls in Windows headers, so let's include it first to avoid clashing with common headers
2017-09-24NETWORKING: Fix mismatched curl callback declaration and definitionBastien Bouclet
2017-09-22NETWORKING: Changed NetworkReadStream not to subclass MemoryReadWriteStreamBastien Bouclet
Also fix the MemoryReadWriteStream managed buffer being leaked. Fixes #9718.
2017-08-11NETWORKING: Fix warningEugene Sandulenko
2017-08-11NETWORKING: Fix data type cast in comparison. char is usually signedEugene Sandulenko
2017-08-06JANITORIAL: Silence some more GCC 7 fall through warningsTorbjörn Andersson
I think these are the last one that were already flagged as being deliberate.
2017-07-17NETWORKING: fix missing SIOCGIFCONF for Haiku (#973)Schrijvers Luc
2017-07-10Revert "COMMON: Change way the Singleton instances are instantiated"Eugene Sandulenko
This reverts commit eefa72afa1978a9dea10f5b1833fcc8f58a3468e. With this patch ConfigManager is broken.
2017-07-10COMMON: Change way the Singleton instances are instantiatedThierry Crozat
This fixes tons of warnings with clang from a recent xcode version on macOS (and possibly other systems) complaining that an instantiation of _singleton is required but no definition is available.
2017-04-29CLOUD: Fix compilation with old curl vesionsThierry Crozat
2017-03-04CLOUD: Fix whitespaceWillem Jan Palenstijn
2017-03-04BACKENDS: NETWORKING: Fix warningEugene Sandulenko
2017-03-04CLOUD: Fix LocalWebserver::resolveAddress() on AndroidAlexander
No <ifaddrs.h> available on Android, thus fixed similarly to https://github.com/zlargon/lssdp/commit/9b4568
2017-01-17CLOUD: Fix Unsigned vs. Signed Comparison Compiler Warning.D G Turner
2017-01-16CLOUD: Fix Possible Uninitialized Variable Compiler Warning.D G Turner
2017-01-16CLOUD: Fix Further Variable Shadowing Compiler Warnings.D G Turner
2017-01-16CLOUD: Fix Compilation Failure.D G Turner
Cut and Paste Typo.
2017-01-16CLOUD: Fix Various Variable Shadowing Compiler Warnings.D G Turner
2017-01-16CLOUD: Fix Various Compiler Warnings By Adding Casts.D G Turner
2017-01-10CLOUD: Fix Two Variable Shadowing Compiler Warnings.D G Turner
2016-09-18CLOUD: Change the cloud icon to be updated by the main threadBastien Bouclet
The cloud manager registers itself as an event source as a mean to be polled periodically by the GUI or engine code. The periodical polling is used to update the OSD icon indicating background sync activity. Also move the cloud icon from ConnectionManager to CloudManager, allowing to decouple icon handling from network connections updates.
2016-09-13CLOUD: Switch to the new OSD APIBastien Bouclet
2016-09-10CLOUD: Move openUrl to OSystemThierry Crozat
2016-09-06CLOUD: Move wwwroot archive to dists and script to devtoolsThierry Crozat
Both the data used to generate the archive and the archive itself were moved to dists/ instead of being in backends/. The script was also improved to optionally take a path as a command line argument to indicate where the wwwroot data are instead of assuming they are in the working directory. Finally a 'wwwroot' make target was also added to invoke the python script and generate the archive. with the expected path to
2016-09-05CLOUD: Fix looking for the wwwroot.zip archiveThierry Crozat
If the themepath was defined but the wwwroot.zip file was not in that path, looking for it failed as it never reached the part of the code using SearchMan to look for it.
2016-09-05CLOUD: Do not error out when loading icon if OSD format is not 2 or 4 BppThierry Crozat
Graphics::TransparentSurface::convertTo() errors out when the destination format is not 2 or 4 Bpp. But in the case of the cloud icon we can recover from it. So just print a warning and don't close the application.
2016-09-03BUILD: Tie the SDL_net version to the SDL versionThierry Crozat
This means that when using SDL 1.2 we use SDL_net 1.2, but when using SDL 2 we now use SLD_net 2 as well. Both versions work properly and there is not code change needed in ScummVM. This change is because SDL_net depends on SDL, and using SDL_net 1.2 with SDL 2 means we can end up needing to link with both the SDL and SDL2 libraries.