Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 33238
b: refs/heads/master
c: 2f34931
h: refs/heads/master
v: v3
  • Loading branch information
Neil Brown authored and Linus Torvalds committed Aug 6, 2006
1 parent aa4daab commit a97b1fc
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 9b7f750d446a717d4c8346fbb165b62661019b92
refs/heads/master: 2f34931fdc78b4895553aaa33748939cc7697c99
6 changes: 5 additions & 1 deletion trunk/net/sunrpc/cache.c
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,12 @@ struct cache_head *sunrpc_cache_lookup(struct cache_detail *detail,
new = detail->alloc();
if (!new)
return NULL;
/* must fully initialise 'new', else
* we might get lose if we need to
* cache_put it soon.
*/
cache_init(new);
detail->init(new, key);

write_lock(&detail->hash_lock);

Expand All @@ -85,7 +90,6 @@ struct cache_head *sunrpc_cache_lookup(struct cache_detail *detail,
return tmp;
}
}
detail->init(new, key);
new->next = *head;
*head = new;
detail->entries++;
Expand Down

0 comments on commit a97b1fc

Please sign in to comment.