git: kernel - Fix bug in lwkt_token_swap()

看板DFBSD_commit作者時間14年前 (2011/10/22 18:03), 編輯推噓0(000)
留言0則, 0人參與, 最新討論串1/1
commit 315422416abed4ef71e97ac2d2a35d23e4a4827a Author: Matthew Dillon <dillon@apollo.backplane.com> Date: Fri Oct 7 00:22:09 2011 -0700 kernel - Fix bug in lwkt_token_swap() * Fix a bug where lwkt_token_swap() would incorrectly assign the ref pointer when the top two tokens on the stack are the same token. When swapping the top two tokens where tok1 == tok2, the token can wind up being repointed to the top ref instead of the deeper ref. When the top ref is released this caused the token to also release even though there was another deeper ref to the same token. * Effected the vm_object traversal code and could cause an object token to be effectively lost without triggering a panic, resulting in corruption. Summary of changes: sys/kern/lwkt_token.c | 29 +++++++++++++++-------------- 1 files changed, 15 insertions(+), 14 deletions(-) http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/315422416abed4ef71e97ac2d2a35d23e4a4827a -- DragonFly BSD source repository
文章代碼(AID): #1EefJmEJ (DFBSD_commit)