Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
emulab
emulab-devel
Commits
baf08e88
Commit
baf08e88
authored
Apr 24, 2006
by
Jonathon Duerig
Browse files
Added a fix which ignores writes to unknown addresses (like the loopback interface).
parent
3cbcd135
Changes
1
Hide whitespace changes
Inline
Side-by-side
pelab/monitor/monitor.py
View file @
baf08e88
...
...
@@ -145,7 +145,10 @@ def get_next_packet():
if
not
size_given
:
size
=
0
total_size
=
total_size
+
size
return
(
ipaddr
,
localport
,
remoteport
,
time
,
size
,
event_code
)
if
emulated_to_real
.
has_key
(
ipaddr
):
return
(
ipaddr
,
localport
,
remoteport
,
time
,
size
,
event_code
)
else
:
return
None
elif
((
netmon_output_version
==
2
)
and
cmatch
):
#
# Watch for new or closed connections
...
...
@@ -167,7 +170,10 @@ def get_next_packet():
sys
.
stdout
.
write
(
'Packet send buffer was set to: '
+
str
(
value
)
+
'
\n
'
)
else
:
return
None
return
(
ipaddr
,
localport
,
remoteport
,
0
,
value
,
event_code
)
if
emulated_to_real
.
has_key
(
ipaddr
):
return
(
ipaddr
,
localport
,
remoteport
,
0
,
value
,
event_code
)
else
:
return
None
else
:
sys
.
stdout
.
write
(
'skipped line in the wrong format: '
+
line
)
return
None
...
...
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