Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
B
babeld
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
babeld
Commits
2afb6362
Commit
2afb6362
authored
Mar 12, 2008
by
Juliusz Chroboczek
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Make sure we don't resend a request to the requestor.
parent
2f30f39e
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
5 deletions
+7
-5
message.c
message.c
+7
-5
No files found.
message.c
View file @
2afb6362
...
@@ -274,18 +274,20 @@ handle_request(struct neighbour *neigh, const unsigned char *prefix,
...
@@ -274,18 +274,20 @@ handle_request(struct neighbour *neigh, const unsigned char *prefix,
struct
route
*
successor_route
;
struct
route
*
successor_route
;
/* We usually want to send the request to our selected successor,
/* We usually want to send the request to our selected successor,
but not when
we suspect that it's dead. So pick the bes
t
but not when
it's the requestor, and not when we suspect tha
t
successor (feasible of not) if our selected successor's
it's dead. So pick the best successor (feasible or not)
metric is suspiciously large. */
if our selected successor's
metric is suspiciously large. */
successor_route
=
find_best_route
(
prefix
,
plen
,
0
,
neigh
);
successor_route
=
find_best_route
(
prefix
,
plen
,
0
,
neigh
);
if
(
!
successor_route
||
successor_route
->
metric
>=
INFINITY
)
if
(
!
successor_route
||
successor_route
->
metric
>=
INFINITY
||
successor_route
->
neigh
==
neigh
)
successor_route
=
route
;
successor_route
=
route
;
else
if
(
route
&&
successor_route
&&
else
if
(
route
&&
successor_route
&&
successor_route
->
metric
+
256
>=
route
->
metric
)
successor_route
->
metric
+
256
>=
route
->
metric
)
successor_route
=
route
;
successor_route
=
route
;
if
(
!
successor_route
||
successor_route
->
metric
>=
INFINITY
)
if
(
!
successor_route
||
successor_route
->
metric
>=
INFINITY
||
successor_route
->
neigh
==
neigh
)
return
;
return
;
send_unicast_request
(
successor_route
->
neigh
,
prefix
,
plen
,
send_unicast_request
(
successor_route
->
neigh
,
prefix
,
plen
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a 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