[master] 0b84709 Avoid platform-dependent documentation
Dridi Boukelmoune
dridi.boukelmoune at gmail.com
Tue Mar 14 15:59:06 CET 2017
commit 0b84709c238fe9c00371a21832ccb58db3b13d92
Author: Dridi Boukelmoune <dridi.boukelmoune at gmail.com>
Date: Tue Mar 14 15:53:33 2017 +0100
Avoid platform-dependent documentation
The varnish-cli will however still report when a parameter is not
available. Spotted by Geoff.
diff --git a/bin/varnishd/mgt/mgt_param.c b/bin/varnishd/mgt/mgt_param.c
index e74cc57..7615228 100644
--- a/bin/varnishd/mgt/mgt_param.c
+++ b/bin/varnishd/mgt/mgt_param.c
@@ -100,6 +100,10 @@ static const char NOT_IMPLEMENTED_TEXT[] =
"This parameter depends on a feature which is not available"
" on this platform.";
+static const char NOT_IMPLEMENTED_DOC[] =
+ "NB: This parameter depends on a feature which is not available"
+ " on all platforms.";
+
/*--------------------------------------------------------------------*/
static struct parspec *
@@ -561,11 +565,8 @@ MCF_DumpRstParam(void)
printf("~");
printf("\n");
- if (pp->flags && pp->flags & NOT_IMPLEMENTED) {
- printf("\nNot Available: %s\n\n",
- NOT_IMPLEMENTED_TEXT);
- continue;
- }
+ if (pp->flags && pp->flags & NOT_IMPLEMENTED)
+ printf("\n%s\n\n", NOT_IMPLEMENTED_DOC);
if (pp->units != NULL && *pp->units != '\0')
printf("\t* Units: %s\n", pp->units);
@@ -583,8 +584,6 @@ MCF_DumpRstParam(void)
printf("\t* Flags: ");
q = "";
- AZ(pp->flags & NOT_IMPLEMENTED);
-
if (pp->flags & DELAYED_EFFECT) {
printf("%sdelayed", q);
q = ", ";
More information about the varnish-commit
mailing list