Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
slash
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
slash
Commits
290673d8
Unverified
Commit
290673d8
authored
Dec 18, 2023
by
Nils Goroll
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Keep track of free dlechg structs
parent
966f8205
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
2 deletions
+7
-2
fellow_log_dle_chg.h
src/fellow_log_dle_chg.h
+7
-2
No files found.
src/fellow_log_dle_chg.h
View file @
290673d8
...
...
@@ -147,7 +147,8 @@ dlechg_pool_fill(struct buddy_reqs *reqs, const void *priv)
struct
fellow_dlechg_top
{
unsigned
magic
;
#define FELLOW_DLECHG_TOP_MAGIC 0x710e71a2
buddy_t
*
buddy
;
unsigned
nfree
;
// mostly debug aid
buddy_t
*
buddy
;
struct
fellow_dlechg_head
head
;
VSLIST_HEAD
(,
fellow_dlechg
)
free
;
struct
dlechg_pool
pool
[
1
];
...
...
@@ -160,8 +161,11 @@ fellow_dlechg_alloc(struct fellow_dlechg_top *fdct)
struct
buddy_ptr_extent
mem
;
fdc
=
VSLIST_FIRST
(
&
fdct
->
free
);
if
(
fdc
!=
NULL
)
if
(
fdc
!=
NULL
)
{
VSLIST_REMOVE_HEAD
(
&
fdct
->
free
,
u
.
freelist
);
AN
(
fdct
->
nfree
);
fdct
->
nfree
--
;
}
else
{
mem
=
buddy_get_next_ptr_extent
(
dlechg_pool_get
(
fdct
->
pool
,
NULL
));
...
...
@@ -296,5 +300,6 @@ fellow_dlechg_get(struct fellow_dlechg_top *fdct, struct fellow_dle *e)
memset
(
fdc
,
0
,
sizeof
*
fdc
);
VSLIST_INSERT_HEAD
(
&
fdct
->
free
,
fdc
,
u
.
freelist
);
fdct
->
nfree
++
;
return
(
e
);
}
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