Commit Graph
26 Commits
Author SHA1 Message Date
Henrik Rydgård 57d22d01d1 Net: reap finished connection threads, and don't echo unsendable close codes
NewThreadExecutor::Run pushed a std::thread per connection and only ever joined them
in the destructor, so a server leaked a joinable thread object for every connection
it had ever served. Measured with 60 connect/disconnect cycles against the debugger:
handle count +60 before, +1 after. Each worker now flags itself done as its last act,
and Run() reaps the finished ones first. Only the accept thread calls Run(), so the
flag is the only thing that needs to be atomic.

Note this doesn't bound how many connections can be in flight at once - it just stops
the finished ones from piling up.

Separately, a received close code was echoed straight back. RFC 6455 7.4.1 reserves
1004, 1005, 1006 and 1015 for describing how a connection ended locally, so they must
never go on the wire - echoing one back would be our protocol violation rather than
the client's. Send PROTOCOL_ERROR when they give us something we can't repeat.
2026-08-31 11:45:53 +02:00
Henrik Rydgård 9b9083d3e5 Fix for headless port problem by Claude 2026-08-16 23:09:12 +02:00
Henrik Rydgård 04ef18a9d9 Send the crash dump output to the debug output stream in headless. This makes it so that crash-failed test output will contain crash details.
Also fix some warnings and stuff.
2026-08-11 22:36:47 +02:00
Henrik Rydgård d31b475bb2 Minor fixes in Common/Net from Nemo's writeup 2026-08-09 19:03:28 +02:00
Henrik Rydgård c686d48268 Add prototype Upload screen and a couple new icons. Some refactoring. 2025-10-27 12:20:20 +01:00
Henrik Rydgård 9218fe9b59 Rework the shutdown logic in the OpenGL backend. Eliminated race conditions. 2025-08-31 10:57:06 +02:00
Henrik Rydgård f6050a442c Fix serving the remote debugger locally, add a setting for the auto-launcher 2025-08-24 11:17:19 +02:00
Henrik Rydgård f2d8d44513 Slightly improved logging (httpserver) 2025-01-14 12:37:56 +01:00
Henrik Rydgård 4dd3621fa0 Remove some unnecessary <algorithm> includes. 2024-12-18 17:04:27 +01:00
Herman Semenov 45429bcd85 [Common/Data/File/Input/Net/Serialize/System/UI] Using for based loop C++17 and replaced on structured binding map C++17 2024-09-17 17:42:08 +02:00
Henrik Rydgård e01ca5b057 Logging API change (refactor) (#19324)
* Rename LogType to Log

* Explicitly use the Log:: enum when logging. Allows for autocomplete when editing.

* Mac/ARM64 buildfix

* Do the same with the hle result log macros

* Rename the log names to mixed case while at it.

* iOS buildfix

* Qt buildfix attempt, ARM32 buildfix
2024-07-14 14:42:59 +02:00
Herman Semenov f75d7d13a0 [Net/Web] Fixed strict reduce types to 32 bit sizes, changed to memsize 2024-05-11 19:43:13 -05:00
Henrik Rydgård f42e9d94a3 Show the tilt input type directly on the item that goes to the tilt settings 2023-12-29 14:10:03 +01:00
Henrik Rydgård e6bc3d83f8 Logging improvement 2023-12-29 11:44:22 +01:00
Herman Semenov 309f0d97f2 [Common Data Net/Core Debugger HLE/GPU Debugger] Fixed reduction data type size to strict 32-bit integer 2023-12-14 19:26:10 +03:00
Henrik Rydgård 93bb113009 Common: Rename Download to Request, and the old Request to ServerRequest. 2023-07-21 22:12:00 +02:00
Henrik Rydgård 6b0903f566 Add facility to run tasks on dedicated threads using the ThreadManager interface.
Useful for things that should be run ASAP even if the threadpool is full,
at a small extra cost. (Not recommended for very small tasks).

Considering using this to resolve the deadlocks in #16802.
2023-01-31 11:07:40 +01:00
Henrik Rydgård 1b0ac23a69 Get rid of Executor.cpp/h.
There was only one implementation.
2021-06-12 13:03:53 +02:00
Henrik Rydgård 3d5c387b3b Minor cleanup 2021-06-12 13:03:53 +02:00
kotcrab 312506a41b Fix crash in HTTPServer when processing invalid request 2021-05-27 14:10:40 +02:00
Unknown W. Brackets 1e22966984 http: Separate out net buffer code from formatting. 2021-05-01 11:20:05 -07:00
Unknown W. Brackets 7e21e9a721 Common: Cleanup some mismatched indentation.
Also move initialization from constructors in a few places.
2021-04-30 22:59:41 -07:00
Henrik Rydgård 9894c74bef Common: Cleanup HTTPServer indentation. 2021-04-30 22:35:25 -07:00
Henrik Rydgård e6aa841b78 Common: Get rid of Executor.cpp/h.
There was only one implementation.
2021-04-30 22:33:34 -07:00
Unknown W. Brackets c3ddb279f9 http: Cleanup excessive logging. 2021-01-01 08:55:18 -08:00
Henrik Rydgård 4f43cff5ca Move fileutil, net, image loaders, ui to Common. (#13506)
* Move and rename file_util/fd_util to Common/File/FileUtil and DirListing

Let's also move net while we're at it.

Move the ZIM/PNG loaders over to Common.

Move the UI framework into Common

iOS buildfix

* Buildfix

* Buildfixes

* Apple buildfix

* This typo again..

* UWP buildfix

* Fix build of PPSSPPQt, such as it is (it's not in good condition...)

* Guess what? Another buildfix.
2020-10-04 20:48:47 +02:00