Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
TPF
tpf-client
Commits
059cd896
Commit
059cd896
authored
Jan 11, 2018
by
Roman Haefeli
Browse files
add clear method to udp_dyn_proxy
parent
6c569547
Changes
1
Hide whitespace changes
Inline
Side-by-side
server/udp_dyn_proxy
View file @
059cd896
...
...
@@ -63,6 +63,12 @@ def addlink():
except
:
sock
.
sendto
(
"Error while executing: "
+
" "
.
join
(
command
)
+
'
\n
'
,
srcaddr
)
def
clear
():
try
:
linklookup
.
clear
()
except
:
sock
.
sendto
(
"Clearing linklookup table failed
\n
"
,
srcaddr
)
def
dellink
():
try
:
ip1
,
port1
,
ip2
,
port2
=
command
[
1
:]
...
...
@@ -80,6 +86,7 @@ def printlinks():
# map command to method calls
methods
=
{
'addlink'
:
addlink
,
'clear'
:
clear
,
'dellink'
:
dellink
,
'printlinks'
:
printlinks
,
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment