Commit 2fa0a2f
committed
Refactor & cleanup logic around post-abort connection shutdown
I don't want to change this behaviour too much as it's all delicate and
poorly understood or tested, but this aborting state is what we hit
after most errors, and triggers a session shutdown, which then results
in downstream RST on any ongoing usage, much like any other silent
connection death.
This change tries to centralize that logic into the session (which is
slowly gaining ownership over session activity) and commonize logic
between the reader, writer & NIO service to link that all together.1 parent ccf6734 commit 2fa0a2f
File tree
3 files changed
+40
-68
lines changed- app/src/main/java/tech/httptoolkit/android/vpn
- socket
3 files changed
+40
-68
lines changedLines changed: 24 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
30 | 30 | | |
31 | 31 | | |
32 | 32 | | |
| 33 | + | |
33 | 34 | | |
| 35 | + | |
34 | 36 | | |
35 | 37 | | |
36 | 38 | | |
| |||
379 | 381 | | |
380 | 382 | | |
381 | 383 | | |
382 | | - | |
| 384 | + | |
| 385 | + | |
| 386 | + | |
| 387 | + | |
| 388 | + | |
| 389 | + | |
| 390 | + | |
| 391 | + | |
| 392 | + | |
| 393 | + | |
| 394 | + | |
| 395 | + | |
| 396 | + | |
| 397 | + | |
| 398 | + | |
| 399 | + | |
| 400 | + | |
| 401 | + | |
| 402 | + | |
| 403 | + | |
| 404 | + | |
| 405 | + | |
383 | 406 | | |
384 | 407 | | |
385 | 408 | | |
| |||
Lines changed: 10 additions & 38 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
48 | 48 | | |
49 | 49 | | |
50 | 50 | | |
51 | | - | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
52 | 56 | | |
53 | | - | |
| 57 | + | |
| 58 | + | |
54 | 59 | | |
55 | | - | |
| 60 | + | |
56 | 61 | | |
57 | 62 | | |
58 | 63 | | |
59 | 64 | | |
60 | 65 | | |
61 | 66 | | |
62 | 67 | | |
63 | | - | |
64 | | - | |
65 | | - | |
66 | | - | |
67 | | - | |
68 | | - | |
69 | | - | |
70 | | - | |
71 | | - | |
72 | | - | |
73 | | - | |
74 | | - | |
75 | | - | |
76 | | - | |
77 | | - | |
78 | | - | |
79 | | - | |
80 | | - | |
81 | | - | |
82 | | - | |
83 | | - | |
84 | | - | |
85 | | - | |
86 | | - | |
87 | | - | |
88 | 68 | | |
89 | 69 | | |
90 | 70 | | |
91 | | - | |
92 | | - | |
93 | | - | |
94 | | - | |
95 | 71 | | |
96 | 72 | | |
97 | 73 | | |
| |||
211 | 187 | | |
212 | 188 | | |
213 | 189 | | |
214 | | - | |
215 | | - | |
216 | | - | |
217 | | - | |
218 | | - | |
| 190 | + | |
219 | 191 | | |
220 | 192 | | |
221 | 193 | | |
| |||
232 | 204 | | |
233 | 205 | | |
234 | 206 | | |
235 | | - | |
| 207 | + | |
236 | 208 | | |
237 | 209 | | |
238 | 210 | | |
| |||
Lines changed: 6 additions & 29 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
48 | 48 | | |
49 | 49 | | |
50 | 50 | | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
51 | 57 | | |
52 | 58 | | |
53 | 59 | | |
| |||
57 | 63 | | |
58 | 64 | | |
59 | 65 | | |
60 | | - | |
61 | | - | |
62 | | - | |
63 | | - | |
64 | | - | |
65 | | - | |
66 | | - | |
67 | | - | |
68 | | - | |
69 | | - | |
70 | | - | |
71 | | - | |
72 | | - | |
73 | | - | |
74 | | - | |
75 | | - | |
76 | | - | |
77 | | - | |
78 | | - | |
79 | | - | |
80 | | - | |
81 | | - | |
82 | | - | |
83 | | - | |
84 | | - | |
85 | | - | |
86 | | - | |
87 | 66 | | |
88 | 67 | | |
89 | 68 | | |
| |||
102 | 81 | | |
103 | 82 | | |
104 | 83 | | |
105 | | - | |
106 | | - | |
107 | 84 | | |
108 | 85 | | |
109 | 86 | | |
| |||
0 commit comments