Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
U
unique-xids
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
uplex-varnish
unique-xids
Commits
c74c4574
Commit
c74c4574
authored
Jun 03, 2012
by
Martin Blix Grydeland
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Free the LRU object and set free_offset when dropping empty segments in smp_close_seg()
Fixes: #1146
parent
1f172c75
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
2 deletions
+6
-2
storage_persistent_silo.c
bin/varnishd/storage/storage_persistent_silo.c
+6
-2
No files found.
bin/varnishd/storage/storage_persistent_silo.c
View file @
c74c4574
...
@@ -253,9 +253,13 @@ smp_close_seg(struct smp_sc *sc, struct smp_seg *sg)
...
@@ -253,9 +253,13 @@ smp_close_seg(struct smp_sc *sc, struct smp_seg *sg)
sc
->
cur_seg
=
NULL
;
sc
->
cur_seg
=
NULL
;
if
(
sg
->
nalloc
==
0
)
{
if
(
sg
->
nalloc
==
0
)
{
/*
XXX: i
f segment is empty, delete instead */
/*
I
f segment is empty, delete instead */
VTAILQ_REMOVE
(
&
sc
->
segments
,
sg
,
list
);
VTAILQ_REMOVE
(
&
sc
->
segments
,
sg
,
list
);
free
(
sg
);
assert
(
sg
->
p
.
offset
>=
sc
->
ident
->
stuff
[
SMP_SPC_STUFF
]);
assert
(
sg
->
p
.
offset
<
sc
->
mediasize
);
sc
->
free_offset
=
sg
->
p
.
offset
;
LRU_Free
(
sg
->
lru
);
FREE_OBJ
(
sg
);
return
;
return
;
}
}
...
...
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