* autotools: removed warning of HAVE_HTTP1 by adding doc-string

* NETCONF 1.1 capability: removed extra, redundant conditional
This commit is contained in:
Olof hagsand 2022-04-03 12:43:54 +02:00
parent 1a9def2f6e
commit aaf8dee44f
4 changed files with 7 additions and 7 deletions

3
configure vendored
View file

@ -5182,7 +5182,8 @@ fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: checking http1 is enabled: $ac_enable_http1" >&5 { $as_echo "$as_me:${as_lineno-$LINENO}: result: checking http1 is enabled: $ac_enable_http1" >&5
$as_echo "checking http1 is enabled: $ac_enable_http1" >&6; } $as_echo "checking http1 is enabled: $ac_enable_http1" >&6; }
if test "$ac_enable_http1" = "yes"; then if test "$ac_enable_http1" = "yes"; then
$as_echo "#define HAVE_HTTP1 true" >>confdefs.h
$as_echo "#define HAVE_HTTP1 true" >>confdefs.h
# Must be tree/false (not 0/1) used in shells # Must be tree/false (not 0/1) used in shells
HAVE_HTTP1=true HAVE_HTTP1=true
fi fi

View file

@ -237,7 +237,7 @@ elif test "x${with_restconf}" == xnative; then
AC_MSG_RESULT(checking http1 is enabled: $ac_enable_http1) AC_MSG_RESULT(checking http1 is enabled: $ac_enable_http1)
if test "$ac_enable_http1" = "yes"; then if test "$ac_enable_http1" = "yes"; then
AC_DEFINE(HAVE_HTTP1,true) # Must be tree/false (not 0/1) used in shells AC_DEFINE(HAVE_HTTP1, true, [Set to true to enable Native HTTP/1]) # Must be tree/false (not 0/1) used in shells
HAVE_HTTP1=true HAVE_HTTP1=true
fi fi

View file

@ -33,6 +33,9 @@
/* Define to 1 if you have the `getresuid' function. */ /* Define to 1 if you have the `getresuid' function. */
#undef HAVE_GETRESUID #undef HAVE_GETRESUID
/* Enable HTTP/1 (default true) */
#undef HAVE_HTTP1
/* Define to 1 if you have the `inet_aton' function. */ /* Define to 1 if you have the `inet_aton' function. */
#undef HAVE_INET_ATON #undef HAVE_INET_ATON
@ -60,9 +63,6 @@
/* Define to 1 if you have the `nghttp2' library (-lnghttp2). */ /* Define to 1 if you have the `nghttp2' library (-lnghttp2). */
#undef HAVE_LIBNGHTTP2 #undef HAVE_LIBNGHTTP2
/* Set to true if HTTP/1 parser */
#undef HAVE_HTTP1
/* Define to 1 if you have the `socket' library (-lsocket). */ /* Define to 1 if you have the `socket' library (-lsocket). */
#undef HAVE_LIBSOCKET #undef HAVE_LIBSOCKET

View file

@ -1701,7 +1701,6 @@ netconf_hello_server(clicon_handle h,
/* Each peer MUST send at least the base NETCONF capability, "urn:ietf:params:netconf:base:1.1" /* Each peer MUST send at least the base NETCONF capability, "urn:ietf:params:netconf:base:1.1"
* RFC 6241 Sec 8.1 * RFC 6241 Sec 8.1
*/ */
if (clicon_option_int(h, "CLICON_NETCONF_BASE_CAPABILITY") > 0) /* RFC 6241 */
cprintf(cb, "<capability>%s</capability>", NETCONF_BASE_CAPABILITY_1_1); cprintf(cb, "<capability>%s</capability>", NETCONF_BASE_CAPABILITY_1_1);
} }
/* A peer MAY include capabilities for previous NETCONF versions, to indicate /* A peer MAY include capabilities for previous NETCONF versions, to indicate