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
cff85bf8
Commit
cff85bf8
authored
Nov 11, 2015
by
Poul-Henning Kamp
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
White space OCD
parent
91d77ac7
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
20 deletions
+20
-20
varnishncsa.c
bin/varnishncsa/varnishncsa.c
+16
-16
varnishncsa_options.h
bin/varnishncsa/varnishncsa_options.h
+4
-4
No files found.
bin/varnishncsa/varnishncsa.c
View file @
cff85bf8
...
@@ -936,23 +936,23 @@ sighup(void)
...
@@ -936,23 +936,23 @@ sighup(void)
static
char
*
static
char
*
read_format
(
const
char
*
formatfile
)
read_format
(
const
char
*
formatfile
)
{
{
FILE
*
fmtfile
;
FILE
*
fmtfile
;
size_t
len
=
0
;
size_t
len
=
0
;
char
*
fmt
=
NULL
;
char
*
fmt
=
NULL
;
fmtfile
=
fopen
(
formatfile
,
"r"
);
fmtfile
=
fopen
(
formatfile
,
"r"
);
if
(
fmtfile
==
NULL
)
if
(
fmtfile
==
NULL
)
VUT_Error
(
1
,
"Can't open format file (%s)"
,
strerror
(
errno
));
VUT_Error
(
1
,
"Can't open format file (%s)"
,
strerror
(
errno
));
if
(
getline
(
&
fmt
,
&
len
,
fmtfile
)
==
-
1
)
{
if
(
getline
(
&
fmt
,
&
len
,
fmtfile
)
==
-
1
)
{
free
(
fmt
);
free
(
fmt
);
if
(
feof
(
fmtfile
))
if
(
feof
(
fmtfile
))
VUT_Error
(
1
,
"Empty format file"
);
VUT_Error
(
1
,
"Empty format file"
);
else
else
VUT_Error
(
1
,
"Can't read format from file (%s)"
,
VUT_Error
(
1
,
"Can't read format from file (%s)"
,
strerror
(
errno
));
strerror
(
errno
));
}
}
fclose
(
fmtfile
);
fclose
(
fmtfile
);
return
(
fmt
);
return
(
fmt
);
}
}
int
int
...
...
bin/varnishncsa/varnishncsa_options.h
View file @
cff85bf8
...
@@ -40,10 +40,10 @@
...
@@ -40,10 +40,10 @@
"Set the output log format string." \
"Set the output log format string." \
)
)
#define NCSA_OPT_f
\
#define NCSA_OPT_f
\
VOPT("f:", "[-f formatfile]", "Read output format from file", \
VOPT("f:", "[-f formatfile]", "Read output format from file", \
"Read output format from a file. Will read a single line" \
"Read output format from a file. Will read a single line" \
" from the specified file, and use that line as the" \
" from the specified file, and use that line as the" \
" format." \
" format." \
)
)
...
...
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