Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
varnish-cache
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
varnishcache
varnish-cache
Commits
ae63cc53
Commit
ae63cc53
authored
May 09, 2016
by
Poul-Henning Kamp
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
We cannot assume that nobody else have killed the object we are
trying to snipe. If they did, fail the sniping. Fixes #1942
parent
3e3357f9
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
3 deletions
+1
-3
cache_hash.c
bin/varnishd/cache/cache_hash.c
+1
-3
No files found.
bin/varnishd/cache/cache_hash.c
View file @
ae63cc53
...
@@ -724,10 +724,8 @@ HSH_Snipe(const struct worker *wrk, struct objcore *oc)
...
@@ -724,10 +724,8 @@ HSH_Snipe(const struct worker *wrk, struct objcore *oc)
CHECK_OBJ_NOTNULL
(
oc
,
OBJCORE_MAGIC
);
CHECK_OBJ_NOTNULL
(
oc
,
OBJCORE_MAGIC
);
CHECK_OBJ_NOTNULL
(
oc
->
objhead
,
OBJHEAD_MAGIC
);
CHECK_OBJ_NOTNULL
(
oc
->
objhead
,
OBJHEAD_MAGIC
);
AZ
(
oc
->
flags
&
OC_F_DYING
);
if
(
oc
->
refcnt
==
1
&&
!
Lck_Trylock
(
&
oc
->
objhead
->
mtx
))
{
if
(
oc
->
refcnt
==
1
&&
!
Lck_Trylock
(
&
oc
->
objhead
->
mtx
))
{
if
(
oc
->
refcnt
==
1
)
{
if
(
oc
->
refcnt
==
1
&&
!
(
oc
->
flags
&
OC_F_DYING
)
)
{
oc
->
flags
|=
OC_F_DYING
;
oc
->
flags
|=
OC_F_DYING
;
oc
->
refcnt
++
;
oc
->
refcnt
++
;
retval
=
1
;
retval
=
1
;
...
...
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