This repository has been archived by the owner on Nov 13, 2023. It is now read-only.
forked from microsoft/cpprestsdk
-
Notifications
You must be signed in to change notification settings - Fork 0
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Related Visual Studio issue: https://developercommunity.visualstudio.com/content/problem/238445/template-class-cant-access-protected-member-when-c.html Problem is with code compiling with /permissive-, so the template functions are affected by this issue.
…ompression is enabled.
* Delete open() from _http_client_communicator and move its functionality into WinHTTP, as that is the only backend using that thing. * Some CR comments from Robert.
utilities::datetime::to_string(): datetime_str and buf were oversized for fitting into output without possible trunctation
gcc-8: -Wno-format-truncation clang-6: -Wdelete-non-virtual-dtor clang-6: -Wunused-lambda-capture removed duplicated: -Wno-reorder This fixes #778
…te certificates set to false
…-config Disable cert revocation check if cert validation is disabled
…should be about 5x faster. (#823) The _Is_word change resulted in the following results in microbenchmarks; the previous is_alnum looks like branching_ranges. .\word_character_test.exe 08/01/18 16:33:03 Running .\word_character_test.exe Run on (12 X 2904 MHz CPU s) CPU Caches: L1 Data 32K (x6) L1 Instruction 32K (x6) L2 Unified 262K (x6) L3 Unified 12582K (x1) -------------------------------------------------------- Benchmark Time CPU Iterations -------------------------------------------------------- strchr_search 19426572900 ns 19421875000 ns 1 branching_ranges 7582129000 ns 7578125000 ns 1 branching_search 6592977800 ns 6593750000 ns 1 table_index 1091321300 ns 1078125000 ns 1
This moves iOS.cmake into the file so there is on need to add it. Also allows for boost to be static libs versus framework
* Improve error handling in on_accept * Move lock to the top of the function * Lock shared data at the right locations. * [http_listener] improve refcount and lifetime management by using RAII.
…nder Unix (#762) * Add asio_connection::was_closed_by_server() to reduce duplication Reduce code duplication between ssl_proxy_tunnel::handle_status_line() and the method with the same name in asio_context itself by moving the common handling of connections closed by server into a new function. No real changes, this is a pure refactoring. * Fix checking for server-side closure of HTTPS connections When an SSL connection times out due to being closed by server, a different error code is returned, so we need to check for it too in was_closed_by_server(). Without this, losing connection was not detected at all when using HTTPS, resulting in "Failed to read HTTP status line" errors whenever the same http_client was reused after more than the server keep alive timeout of inactivity. See #592. * Fix bug with using re-opened connections with ASIO Creating a new request when the existing connection being used was closed by the server didn't work correctly because the associated input stream was already exhausted, as its contents had been already "sent" to the server using the now discarded connection, so starting a new request using the same body stream never worked. Fix this by explicitly rewinding the stream to the beginning before using it again. Note that even with this fix using a custom body stream which is not positioned at the beginning initially (or which doesn't support rewinding) still wouldn't work, but at least it fixes the most common use case. See #592. * Reduce duplicate code between ssl_proxy and asio_context in handle_read_status_line. Avoid increasing public surface with rewind function.
…tion (#737) * Update CMakeLists.txt to install the cmake bindings in the right location /usr/lib/cpprestsdk is not the correct FHS standard cmake location. It should be placed in /usr/lib/<triplet>/cmake/cpprestsdk instead. Same goes for libraries, support multiarch location if we use UNIX * Revert changes to CPPREST_EXPORT_DIR. Use GNUInstallDirs on all platforms.
…rides so far (#818) * Microperf: Use lock_guard instead of unique_lock. * Bill hates lock_guard more. * Ref them connections. * Demacroize. * Commonize port and merge some CRLFs into adjacent string literals. * Add missing template keyword. * Avoid stringstream in constructing the proxy_str. * Remove unused forward declarations of some HTTP things. * Use NOMINMAX instead of undef min and max everywhere. * Bunch of inheritance hygiene. * What do you mean you want examples to compile? * More CR comments from Robert. * Add static. * Use existing to_string_t.
Some files don't have a space inbetween the '<' and '::' charachters, which will cause build failures on older toolchains. Adding a space inbetween these two characters fixes the issue. See http://autobuild.buildroot.net/results/797a9b5fdf6ab0f16f2249324b48292dfab61d9f/build-end.log for more information.
AND_CAPTURE_MEMBER_FUNCTION_POINTERS workaround had a check for GCC, but did not exclude Clang. Clang has a fake GCC version of 4.2, thus caused problems.
* json: {"meow"} is not a valid object * Add to contributors - eighteenth PR seemed like the time! :-)
* Update vcpkg. * Attempt to fix Ubuntu apt and update MacOS. * Workaround Azure Pipelines forcing an updated copy of boost that doesn't work with default Ubuntu libs. * Add test runs back. * Update boost-for-android and block Boost 1.69 on the image. * Update boost and openssl on iOS. * Use right path to test binaries. * Shut off iOS builds.
The default behavior for tcp::resolver::query uses the address_configured flag, which only returns addresses if a non-loopback address is available on the system. If this is called before a real network interface is brought up, then resolution will fail and the server won't be functional, even for requests on the loopback interface. Explicitly set the flags to default so that the address_configured flag is not specified. This allows the server to start up normally even when the system has no active network interfaces.
Add ping and pong to message handler, and optional pong timeout
Calling request() twice on the same client configured to connect to a server via HTTPS didn't work under Unix because we issues CONNECT for every request, meaning that, for the second one, we sent CONNECT via an already established connection to the end server itself which, unsurprisingly, didn't work at all. Fix this by only setting up SSL tunnelling for a new connection but not for the already used one.
…ew. (#1185) * Update boost-for-android for Android NDK r20. * Also disable homebrew. * I mean homebrew I said! * Apparently Android isn't ready for Boost 1.70 yet.
* Remove invalid static_assert(false). * Turn on permissive-. * clang-format
…cleanup (#1187) * Audit for "" and use std::string default ctor instead. * Fix Linux ambiguity. * Exclude common build directories. * Replace CPPREST_TARGET_XP with checks against _WIN32_WINNT to allow more fine grained controls going forward (e.g. assume Win10). Also fix a few typos. * Delete CASABLANCA_UNREFERENCED_PARAMETER and attempt Linux compile fix. * Defend NOMINMAX. * Another _WIN32 guard. * With && this time. * Fix more spelling errors. * Optimize trim_nulls slightly. * And actually make the optimization correct this time. * Fix unit test failure. * clang-format
) * Remove proxy settings detection behavior in "default proxy mode." This commit partially reverts eb108ad in order to work around a reliability problem with WinHttpGetProxyForUrl. That function hangs unless there is an available thread pool thread to complete the WPAD request. As a result, if a customer issued ~512 concurrent HTTP requests, or otherwise needed that many thread pool threads, there would not be a thread available for WinHTTP to complete the operation, and the program would deadlock. Moreover this call to WinHttpGetDefaultProxyConfiguration is extremely expensive, taking ~20% of overall CPU for the entire program for some Azure Storage SDK customers. The function WinHttpGetProxyForUrlEx is supposed to help with this problem by being asynchronous, but that function was added in Windows 8, so we can't use it unconditionally. And on Windows 8.1 we already are using WINHTTP_ACCESS_TYPE_AUTOMATIC_PROXY instead of trying to do proxy autodetect ourselves.
* Workarounds for two GCC 4.7.2 bugs with lambda functions using implicit this, surfacing as incorrect const-qualification and an internal compiler error. Resolves immediate issues identified in #1200. * Restore compatibility with modern compilers
* On basic_string_view_support: fix SxS debug-release builds with Visual Studio place precompiled header implicitly in Debug/Release path with VS and explicitly in bin dir otherwise standardize pch setup across libraries with helper function * nudge pipeline to rerun
… the indices of these values match the HTTP_HEADER_ID values for HTTP_REQUEST_HEADERS but *not* HTTP_RESPONSE_HEADERS (#1219)
…mes fires false positive error "There are no pending calls to next_request." (#1196)
* Also add VS2019 configurations to Azure Pipelines. * Also turn on vcpkg caching from @lukka
…ient_winhttp.cpp does not. (#1253)
…kout failure on CircleCI with git 2.22.0 (#1263)
Womp, merge conflicts :( |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
No description provided.