Commit 03b80bc
refactor: drop redundant webserver_impl::log_dispatch_error forwarder
There were two log_dispatch_error: the real free function
detail::log_dispatch_error(const webserver_config&, string_view) in
dispatch_util.cpp, and a one-line webserver_impl member that merely forwarded
to it (parent->config, msg). The member's only two callers were the v1 auth
alias hooks in webserver_aliases.cpp, which already have the owning webserver*
(ws_ptr) in scope — so they can call the free function directly with
ws_ptr->config.
Point those two call sites at detail::log_dispatch_error, drop the member
declaration (webserver_impl_dispatch.hpp) and its definition, and delete the
9-SLOC webserver_error_pages.cpp TU that existed solely to hold it. Removes a
duplicate function and a translation unit; no behavior change.
Local: builds, 113/113 tests pass, file-size + complexity + cpplint gates green.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015tAodxYJMEY4VxCX4dk62e1 parent e6bc48e commit 03b80bc
4 files changed
Lines changed: 9 additions & 70 deletions
File tree
- src
- detail
- httpserver/detail
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
28 | | - | |
| 28 | + | |
29 | 29 | | |
30 | 30 | | |
31 | 31 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
64 | 64 | | |
65 | 65 | | |
66 | 66 | | |
| 67 | + | |
67 | 68 | | |
68 | 69 | | |
69 | 70 | | |
| |||
244 | 245 | | |
245 | 246 | | |
246 | 247 | | |
247 | | - | |
| 248 | + | |
248 | 249 | | |
249 | 250 | | |
250 | 251 | | |
251 | 252 | | |
252 | | - | |
| 253 | + | |
253 | 254 | | |
254 | 255 | | |
255 | 256 | | |
| |||
This file was deleted.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
42 | 42 | | |
43 | 43 | | |
44 | 44 | | |
45 | | - | |
46 | | - | |
47 | | - | |
48 | | - | |
49 | | - | |
50 | | - | |
51 | | - | |
52 | | - | |
53 | | - | |
54 | | - | |
55 | | - | |
56 | | - | |
57 | | - | |
58 | | - | |
59 | | - | |
60 | | - | |
61 | | - | |
62 | | - | |
63 | | - | |
64 | | - | |
65 | | - | |
66 | | - | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
67 | 50 | | |
68 | 51 | | |
69 | 52 | | |
| |||
0 commit comments