Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cache: fix new object in callback v2 on updated objects #381

Closed
wants to merge 1 commit into from

Conversation

KanjiMonster
Copy link
Contributor

When calling the callback v2 for objects that were updated, we pass the update ("obj") instead of the updated object ("old") as new.

Presumably this wasn't intended, so pass the updated object as new.

This avoids weird updates where the new object is significantly smaller than the old one. E.g. for IPv6 multipath route updates, old would be the full route with all nexthops, while new would be a partial route with only the added/removed nexthop.

Fixes: 66d032a ("cache_mngr: add include callback v2")

When calling the callback v2 for objects that were updated, we pass the
update ("obj") instead of the updated object ("old") as new.

Presumably this wasn't intended, so pass the updated object as new.

This avoids weird updates where the new object is significantly smaller
than the old one. E.g. for IPv6 multipath route updates, old would be
the full route with all nexthops, while new would be a partial route
with only the added/removed nexthop.

Fixes: 66d032a ("cache_mngr: add include callback v2")
Signed-off-by: Jonas Gorski <[email protected]>
thom311 pushed a commit that referenced this pull request Apr 26, 2024
When calling the callback v2 for objects that were updated, we pass the
update ("obj") instead of the updated object ("old") as new.

Presumably this wasn't intended, so pass the updated object as new.

This avoids weird updates where the new object is significantly smaller
than the old one. E.g. for IPv6 multipath route updates, old would be
the full route with all nexthops, while new would be a partial route
with only the added/removed nexthop.

Fixes: 66d032a ("cache_mngr: add include callback v2")
Signed-off-by: Jonas Gorski <[email protected]>

#381
@thom311
Copy link
Owner

thom311 commented Apr 26, 2024

lgtm. Thank you!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants