Commit 0d5dcf4
tools/tcpcong: Reduce code redundancy
1: Ports that do not meet the conditions in function
"entry_state_update_func" will not be stored in the "start_ipv4" or "start_ipv6",
and the "ret_state_update_func" function will not obtain values,
so there is no need to perform port filtering again.
2: Sock_store can be directly deleted in function "ret_func".
Signed-off-by: Feng Yang <[email protected]>1 parent 321f8b1 commit 0d5dcf4
1 file changed
+4
-12
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
199 | 199 | | |
200 | 200 | | |
201 | 201 | | |
202 | | - | |
203 | 202 | | |
204 | 203 | | |
205 | 204 | | |
| |||
216 | 215 | | |
217 | 216 | | |
218 | 217 | | |
219 | | - | |
220 | 218 | | |
221 | 219 | | |
222 | 220 | | |
223 | 221 | | |
224 | 222 | | |
225 | | - | |
226 | | - | |
227 | | - | |
228 | | - | |
| 223 | + | |
229 | 224 | | |
230 | 225 | | |
231 | 226 | | |
| |||
246 | 241 | | |
247 | 242 | | |
248 | 243 | | |
249 | | - | |
250 | 244 | | |
251 | 245 | | |
252 | 246 | | |
253 | 247 | | |
254 | 248 | | |
255 | | - | |
256 | | - | |
257 | | - | |
258 | | - | |
| 249 | + | |
259 | 250 | | |
260 | 251 | | |
261 | 252 | | |
| |||
274 | 265 | | |
275 | 266 | | |
276 | 267 | | |
277 | | - | |
| 268 | + | |
278 | 269 | | |
279 | 270 | | |
280 | 271 | | |
| |||
366 | 357 | | |
367 | 358 | | |
368 | 359 | | |
| 360 | + | |
369 | 361 | | |
370 | 362 | | |
371 | 363 | | |
| |||
0 commit comments