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
6b84197e
Commit
6b84197e
authored
Nov 23, 2011
by
Andreas Plesner Jacobsen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Spelling cleanup
parent
a8aa0baf
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
10 additions
and
10 deletions
+10
-10
vsl.h
include/vapi/vsl.h
+2
-2
vsm.h
include/vapi/vsm.h
+4
-4
vsm_int.h
include/vapi/vsm_int.h
+1
-1
vsm.c
lib/libvarnishapi/vsm.c
+3
-3
No files found.
include/vapi/vsl.h
View file @
6b84197e
...
@@ -121,7 +121,7 @@ int VSL_Dispatch(struct VSM_data *vd, VSL_handler_f *func, void *priv);
...
@@ -121,7 +121,7 @@ int VSL_Dispatch(struct VSM_data *vd, VSL_handler_f *func, void *priv);
* Return values:
* Return values:
* !=0: Non-zero return value from func()
* !=0: Non-zero return value from func()
* 0: no VSL records.
* 0: no VSL records.
* -1: VSL chunk was abandon
n
ed.
* -1: VSL chunk was abandoned.
* -2: End of file (-r) / -k arg exhausted / "done"
* -2: End of file (-r) / -k arg exhausted / "done"
*/
*/
...
@@ -132,7 +132,7 @@ int VSL_NextSLT(struct VSM_data *lh, uint32_t **pp, uint64_t *bitmap);
...
@@ -132,7 +132,7 @@ int VSL_NextSLT(struct VSM_data *lh, uint32_t **pp, uint64_t *bitmap);
* Return values:
* Return values:
* 1: Valid VSL record at *pp
* 1: Valid VSL record at *pp
* 0: no VSL records
* 0: no VSL records
* -1: VSL c
unkwas abandon
ned
* -1: VSL c
hunk was abando
ned
* -2: End of file (-r) / -k arg exhausted / "done"
* -2: End of file (-r) / -k arg exhausted / "done"
*/
*/
...
...
include/vapi/vsm.h
View file @
6b84197e
...
@@ -100,16 +100,16 @@ int VSM_Open(struct VSM_data *vd);
...
@@ -100,16 +100,16 @@ int VSM_Open(struct VSM_data *vd);
* <0 on failure, VSM_Error() returns diagnostic string
* <0 on failure, VSM_Error() returns diagnostic string
*/
*/
int
VSM_Abandon
n
ed
(
const
struct
VSM_data
*
vd
);
int
VSM_Abandoned
(
const
struct
VSM_data
*
vd
);
/*
/*
* Find out if the VSM file has been abandon
n
ed or closed and should
* Find out if the VSM file has been abandoned or closed and should
* be reopened. This function calls stat(2) and should only be
* be reopened. This function calls stat(2) and should only be
* used when lack of activity or invalidation of fantoms indicate
* used when lack of activity or invalidation of fantoms indicate
* abandonment.
* abandonment.
*
*
* Returns:
* Returns:
* 0 No reopen needed.
* 0 No reopen needed.
* 1 VSM abandon
n
ed.
* 1 VSM abandoned.
*/
*/
void
VSM_Close
(
struct
VSM_data
*
vd
);
void
VSM_Close
(
struct
VSM_data
*
vd
);
...
@@ -132,7 +132,7 @@ int VSM__itern(const struct VSM_data *vd, struct VSM_fantom *vf);
...
@@ -132,7 +132,7 @@ int VSM__itern(const struct VSM_data *vd, struct VSM_fantom *vf);
int
VSM_StillValid
(
const
struct
VSM_data
*
vd
,
struct
VSM_fantom
*
vf
);
int
VSM_StillValid
(
const
struct
VSM_data
*
vd
,
struct
VSM_fantom
*
vf
);
/*
/*
* This is a cheap syscall-less check to see if the fantom is still
* This is a cheap syscall-less check to see if the fantom is still
* valid. Further checking with VSM_Abandon
n
ed() may be a good
* valid. Further checking with VSM_Abandoned() may be a good
* idea.
* idea.
*
*
* Return:
* Return:
...
...
include/vapi/vsm_int.h
View file @
6b84197e
...
@@ -50,7 +50,7 @@
...
@@ -50,7 +50,7 @@
* When manager abandons VSM file, alloc_seq is set to zero, which
* When manager abandons VSM file, alloc_seq is set to zero, which
* never happens in any other circumstances.
* never happens in any other circumstances.
*
*
* If a manager is started and finds and old abandon
n
ed VSM segment
* If a manager is started and finds and old abandoned VSM segment
* it will zero the alloc_seq in it, before replacing the file.
* it will zero the alloc_seq in it, before replacing the file.
*
*
* Subscribers will have to monitor two things to make sure they have
* Subscribers will have to monitor two things to make sure they have
...
...
lib/libvarnishapi/vsm.c
View file @
6b84197e
...
@@ -245,7 +245,7 @@ VSM_Close(struct VSM_data *vd)
...
@@ -245,7 +245,7 @@ VSM_Close(struct VSM_data *vd)
/*--------------------------------------------------------------------*/
/*--------------------------------------------------------------------*/
int
int
VSM_Abandon
n
ed
(
const
struct
VSM_data
*
vd
)
VSM_Abandoned
(
const
struct
VSM_data
*
vd
)
{
{
struct
stat
st
;
struct
stat
st
;
...
@@ -287,7 +287,7 @@ VSM__itern(const struct VSM_data *vd, struct VSM_fantom *vf)
...
@@ -287,7 +287,7 @@ VSM__itern(const struct VSM_data *vd, struct VSM_fantom *vf)
AN
(
vf
);
AN
(
vf
);
if
(
vd
->
head
->
alloc_seq
==
0
)
if
(
vd
->
head
->
alloc_seq
==
0
)
return
(
0
);
/* abandon
n
ed VSM */
return
(
0
);
/* abandoned VSM */
else
if
(
vf
->
priv
!=
0
)
{
else
if
(
vf
->
priv
!=
0
)
{
if
(
vf
->
priv
!=
vd
->
head
->
alloc_seq
)
if
(
vf
->
priv
!=
vd
->
head
->
alloc_seq
)
return
(
0
);
return
(
0
);
...
@@ -312,7 +312,7 @@ VSM__itern(const struct VSM_data *vd, struct VSM_fantom *vf)
...
@@ -312,7 +312,7 @@ VSM__itern(const struct VSM_data *vd, struct VSM_fantom *vf)
vf
->
e
=
(
char
*
)
vf
->
b
+
vf
->
chunk
->
len
;
vf
->
e
=
(
char
*
)
vf
->
b
+
vf
->
chunk
->
len
;
if
(
vf
->
priv
==
0
)
if
(
vf
->
priv
==
0
)
return
(
0
);
/* abandon
n
ed VSM */
return
(
0
);
/* abandoned VSM */
if
(
vf
->
b
==
vf
->
e
)
if
(
vf
->
b
==
vf
->
e
)
return
(
0
);
/* freed chunk */
return
(
0
);
/* freed chunk */
AN
(
vf
->
priv
);
AN
(
vf
->
priv
);
...
...
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