Remove extra lines
This commit is contained in:
parent
3332dfef20
commit
69eaf98913
72 changed files with 1 additions and 98 deletions
|
|
@ -35,7 +35,6 @@
|
||||||
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#ifndef _BACKEND_SOCKET_H_
|
#ifndef _BACKEND_SOCKET_H_
|
||||||
#define _BACKEND_SOCKET_H_
|
#define _BACKEND_SOCKET_H_
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -113,7 +113,6 @@ running |--------+------------> RUNNING
|
||||||
parse validate OK / commit
|
parse validate OK / commit
|
||||||
startup -------+--+-------+------------+
|
startup -------+--+-------+------------+
|
||||||
|
|
||||||
|
|
||||||
INVALID (requires manual edit of candidate)
|
INVALID (requires manual edit of candidate)
|
||||||
failsafe ----------------------+
|
failsafe ----------------------+
|
||||||
reset \ commit
|
reset \ commit
|
||||||
|
|
|
||||||
|
|
@ -35,7 +35,6 @@
|
||||||
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#ifndef _BACKEND_STARTUP_H_
|
#ifndef _BACKEND_STARTUP_H_
|
||||||
#define _BACKEND_STARTUP_H_
|
#define _BACKEND_STARTUP_H_
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -60,4 +60,3 @@ extern "C" {
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
} /* extern "C" */
|
} /* extern "C" */
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -35,7 +35,6 @@
|
||||||
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#ifndef _CLIXON_BACKEND_COMMIT_H_
|
#ifndef _CLIXON_BACKEND_COMMIT_H_
|
||||||
#define _CLIXON_BACKEND_COMMIT_H_
|
#define _CLIXON_BACKEND_COMMIT_H_
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -234,4 +234,3 @@ backend_client_print(clixon_handle h,
|
||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -65,7 +65,6 @@ int transaction_print(FILE *f, transaction_data th);
|
||||||
int transaction_dbg(clixon_handle h, int dbglevel, transaction_data th, const char *msg);
|
int transaction_dbg(clixon_handle h, int dbglevel, transaction_data th, const char *msg);
|
||||||
int transaction_log(clixon_handle h, transaction_data th, int level, const char *op);
|
int transaction_log(clixon_handle h, transaction_data th, int level, const char *op);
|
||||||
|
|
||||||
|
|
||||||
/* Pagination callbacks
|
/* Pagination callbacks
|
||||||
* @see pagination_data_t internal structure
|
* @see pagination_data_t internal structure
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -72,7 +72,6 @@ static const map_str2int list_kw_map[] = {
|
||||||
{NULL, -1}
|
{NULL, -1}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
static int
|
static int
|
||||||
autocli_str2op(char *str)
|
autocli_str2op(char *str)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -830,7 +830,6 @@ cli_start_program(clixon_handle h,
|
||||||
size_t bufsize = 0;
|
size_t bufsize = 0;
|
||||||
struct passwd pw, *pwresult = NULL;
|
struct passwd pw, *pwresult = NULL;
|
||||||
|
|
||||||
|
|
||||||
/* Check parameters */
|
/* Check parameters */
|
||||||
if (cvec_len(argv) == 0){
|
if (cvec_len(argv) == 0){
|
||||||
clixon_err(OE_PLUGIN, EINVAL, "Can not find argument");
|
clixon_err(OE_PLUGIN, EINVAL, "Can not find argument");
|
||||||
|
|
|
||||||
|
|
@ -796,4 +796,3 @@ cli_syntax_mode(clixon_handle h)
|
||||||
return NULL;
|
return NULL;
|
||||||
return cligen_ph_name_get(ph);
|
return cligen_ph_name_get(ph);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -45,7 +45,6 @@
|
||||||
/* clicon generic callback pointer */
|
/* clicon generic callback pointer */
|
||||||
typedef void (clicon_callback_t)(clixon_handle h);
|
typedef void (clicon_callback_t)(clixon_handle h);
|
||||||
|
|
||||||
|
|
||||||
void *clixon_str2fn(char *name, void *handle, char **error);
|
void *clixon_str2fn(char *name, void *handle, char **error);
|
||||||
|
|
||||||
int clicon_parse(clixon_handle h, char *cmd, char **mode, cligen_result *result, int *evalres);
|
int clicon_parse(clixon_handle h, char *cmd, char **mode, cligen_result *result, int *evalres);
|
||||||
|
|
|
||||||
|
|
@ -70,4 +70,3 @@ int plugin_exit(clixon_handle h);
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
} /* extern "C" */
|
} /* extern "C" */
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -50,5 +50,4 @@ int netconf_xpath(cxobj *xsearch,
|
||||||
cbuf *xf, cbuf *xf_err,
|
cbuf *xf, cbuf *xf_err,
|
||||||
cxobj *xt);
|
cxobj *xt);
|
||||||
|
|
||||||
|
|
||||||
#endif /* _CLIXON_NETCONF_H_ */
|
#endif /* _CLIXON_NETCONF_H_ */
|
||||||
|
|
|
||||||
|
|
@ -211,4 +211,3 @@ xml_filter(cxobj *xfilter,
|
||||||
&remove_s);
|
&remove_s);
|
||||||
return retval;
|
return retval;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -368,7 +368,6 @@ field_values : field_vchars
|
||||||
| { $$ = NULL; _PARSE_DEBUG("field-values -> "); }
|
| { $$ = NULL; _PARSE_DEBUG("field-values -> "); }
|
||||||
;
|
;
|
||||||
|
|
||||||
|
|
||||||
field_vchars : field_vchars RWS VCHARS
|
field_vchars : field_vchars RWS VCHARS
|
||||||
{
|
{
|
||||||
if (($$ = clixon_string_del_join($1, " ", $3)) == NULL) YYABORT;
|
if (($$ = clixon_string_del_join($1, " ", $3)) == NULL) YYABORT;
|
||||||
|
|
@ -393,4 +392,3 @@ ows : RWS
|
||||||
;
|
;
|
||||||
|
|
||||||
%%
|
%%
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -35,7 +35,6 @@
|
||||||
* Limited static http data service embedded in restconf code
|
* Limited static http data service embedded in restconf code
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#ifdef HAVE_CONFIG_H
|
#ifdef HAVE_CONFIG_H
|
||||||
#include "clixon_config.h" /* generated by config & autoconf */
|
#include "clixon_config.h" /* generated by config & autoconf */
|
||||||
#endif
|
#endif
|
||||||
|
|
|
||||||
|
|
@ -82,4 +82,3 @@ int restconf_param_set(clixon_handle h, const char *param, char *val);
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
} /* extern "C" */
|
} /* extern "C" */
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -67,7 +67,6 @@
|
||||||
#include "restconf_lib.h"
|
#include "restconf_lib.h"
|
||||||
#include "restconf_api.h" /* Virtual api */
|
#include "restconf_api.h" /* Virtual api */
|
||||||
|
|
||||||
|
|
||||||
/*! HTTP headers done, if there is a message body coming next
|
/*! HTTP headers done, if there is a message body coming next
|
||||||
*
|
*
|
||||||
* @param[in] req Fastcgi request handle
|
* @param[in] req Fastcgi request handle
|
||||||
|
|
|
||||||
|
|
@ -204,4 +204,3 @@ restconf_get_indata(void *req0)
|
||||||
done:
|
done:
|
||||||
return cb;
|
return cb;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -34,8 +34,6 @@
|
||||||
*
|
*
|
||||||
* Return errors
|
* Return errors
|
||||||
* @see RFC 7231 Hypertext Transfer Protocol (HTTP/1.1): Semantics and Content
|
* @see RFC 7231 Hypertext Transfer Protocol (HTTP/1.1): Semantics and Content
|
||||||
|
|
||||||
|
|
||||||
* "api-path" is "URI-encoded path expression" definition in RFC8040 3.5.3
|
* "api-path" is "URI-encoded path expression" definition in RFC8040 3.5.3
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -51,5 +51,4 @@ int restconf_notimplemented(clixon_handle h, void *req, int pretty, restconf_med
|
||||||
int api_return_err(clixon_handle h, void *req, cxobj *xerr, int pretty, restconf_media media, int code0);
|
int api_return_err(clixon_handle h, void *req, cxobj *xerr, int pretty, restconf_media media, int code0);
|
||||||
int api_return_err0(clixon_handle h, void *req, cxobj *xerr, int pretty, restconf_media media, int code0);
|
int api_return_err0(clixon_handle h, void *req, cxobj *xerr, int pretty, restconf_media media, int code0);
|
||||||
|
|
||||||
|
|
||||||
#endif /* _RESTCONF_ERR_H_ */
|
#endif /* _RESTCONF_ERR_H_ */
|
||||||
|
|
|
||||||
|
|
@ -930,4 +930,3 @@ restconf_socket_init(const char *netns0,
|
||||||
clixon_debug(CLIXON_DBG_RESTCONF, "retval:%d", retval);
|
clixon_debug(CLIXON_DBG_RESTCONF, "retval:%d", retval);
|
||||||
return retval;
|
return retval;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -427,7 +427,6 @@ restconf_ssl_context_configure(clixon_handle h,
|
||||||
SSL_CTX_set_verify_depth(ctx, VERIFY_DEPTH+1);
|
SSL_CTX_set_verify_depth(ctx, VERIFY_DEPTH+1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
X509_STORE_set_flags(SSL_CTX_get_cert_store(ctx), 0);
|
X509_STORE_set_flags(SSL_CTX_get_cert_store(ctx), 0);
|
||||||
|
|
||||||
SSL_CTX_set_session_id_context(ctx, (void *)&session_id_context, sizeof(session_id_context));
|
SSL_CTX_set_session_id_context(ctx, (void *)&session_id_context, sizeof(session_id_context));
|
||||||
|
|
|
||||||
|
|
@ -824,4 +824,3 @@ api_data_delete(clixon_handle h,
|
||||||
clixon_debug(CLIXON_DBG_RESTCONF, "retval:%d", retval);
|
clixon_debug(CLIXON_DBG_RESTCONF, "retval:%d", retval);
|
||||||
return retval;
|
return retval;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -795,4 +795,3 @@ api_operations_get(clixon_handle h,
|
||||||
xml_free(xt);
|
xml_free(xt);
|
||||||
return retval;
|
return retval;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -36,7 +36,6 @@
|
||||||
* Restconf YANG PATCH implementation (RFC8072)
|
* Restconf YANG PATCH implementation (RFC8072)
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#ifdef HAVE_CONFIG_H
|
#ifdef HAVE_CONFIG_H
|
||||||
#include "clixon_config.h" /* generated by config & autoconf */
|
#include "clixon_config.h" /* generated by config & autoconf */
|
||||||
#endif
|
#endif
|
||||||
|
|
|
||||||
|
|
@ -36,7 +36,6 @@
|
||||||
* Restconf YANG PATCH implementation (RFC8072)
|
* Restconf YANG PATCH implementation (RFC8072)
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#ifndef _RESTCONF_METHODS_PATCH_H_
|
#ifndef _RESTCONF_METHODS_PATCH_H_
|
||||||
#define _RESTCONF_METHODS_PATCH_H_
|
#define _RESTCONF_METHODS_PATCH_H_
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -36,7 +36,6 @@
|
||||||
* From RFC 8040 Section 4.4. POST
|
* From RFC 8040 Section 4.4. POST
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#ifdef HAVE_CONFIG_H
|
#ifdef HAVE_CONFIG_H
|
||||||
#include "clixon_config.h" /* generated by config & autoconf */
|
#include "clixon_config.h" /* generated by config & autoconf */
|
||||||
#endif
|
#endif
|
||||||
|
|
|
||||||
|
|
@ -1870,4 +1870,3 @@ restconf_socket_extract(clixon_handle h,
|
||||||
free(reason);
|
free(reason);
|
||||||
return retval;
|
return retval;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -189,8 +189,6 @@ int restconf_callhome_timer(restconf_socket *rsock, int status);
|
||||||
int restconf_socket_extract(clixon_handle h, cxobj *xs, cvec *nsc, restconf_socket *rsock,
|
int restconf_socket_extract(clixon_handle h, cxobj *xs, cvec *nsc, restconf_socket *rsock,
|
||||||
char **namespace, char **address, char **addrtype, uint16_t *port);
|
char **namespace, char **address, char **addrtype, uint16_t *port);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#endif /* _RESTCONF_NATIVE_H_ */
|
#endif /* _RESTCONF_NATIVE_H_ */
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
|
|
|
||||||
|
|
@ -34,7 +34,6 @@
|
||||||
* Generic restconf root handlers eg for /restconf /.well-known, etc
|
* Generic restconf root handlers eg for /restconf /.well-known, etc
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#ifdef HAVE_CONFIG_H
|
#ifdef HAVE_CONFIG_H
|
||||||
#include "clixon_config.h" /* generated by config & autoconf */
|
#include "clixon_config.h" /* generated by config & autoconf */
|
||||||
#endif
|
#endif
|
||||||
|
|
@ -641,4 +640,3 @@ api_root_restconf(clixon_handle h,
|
||||||
free(path);
|
free(path);
|
||||||
return retval;
|
return retval;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1149,8 +1149,6 @@ snmp_table_set(clixon_handle h,
|
||||||
goto done;
|
goto done;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/*! Use a cache for getnext tables instead of an RPC to the backend every time
|
/*! Use a cache for getnext tables instead of an RPC to the backend every time
|
||||||
*
|
*
|
||||||
* The cache works as follows:
|
* The cache works as follows:
|
||||||
|
|
|
||||||
|
|
@ -59,4 +59,3 @@ int clixon_snmp_table_exit(clixon_handle h);
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
} /* extern "C" */
|
} /* extern "C" */
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -112,7 +112,6 @@ static const map_str2int snmp_type_map[] = {
|
||||||
{NULL, -1}
|
{NULL, -1}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
/* Map between clixon "orig" resolved type and ASN.1 types.
|
/* Map between clixon "orig" resolved type and ASN.1 types.
|
||||||
*/
|
*/
|
||||||
static const map_str2int snmp_orig_map[] = {
|
static const map_str2int snmp_orig_map[] = {
|
||||||
|
|
@ -157,7 +156,6 @@ static const map_str2str yang_snmp_types[] = {
|
||||||
{ NULL, NULL} /* if not found */
|
{ NULL, NULL} /* if not found */
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
/*! A function that checks that all subtypes of the union are the same
|
/*! A function that checks that all subtypes of the union are the same
|
||||||
*
|
*
|
||||||
* @param[in] ytype Yang resolved type (a union in this case)
|
* @param[in] ytype Yang resolved type (a union in this case)
|
||||||
|
|
@ -515,7 +513,6 @@ yangext_is_oid_exist(yang_stmt *yn)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/*! Duplicate clixon snmp handler struct
|
/*! Duplicate clixon snmp handler struct
|
||||||
*
|
*
|
||||||
* Use signature of libnetsnmp data_clone field of netsnmp_mib_handler in agent_handler.h
|
* Use signature of libnetsnmp data_clone field of netsnmp_mib_handler in agent_handler.h
|
||||||
|
|
|
||||||
|
|
@ -119,4 +119,3 @@ int clixon_snmp_api_oid_find(oid *oid1, size_t oidlen);
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
} /* extern "C" */
|
} /* extern "C" */
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -52,4 +52,3 @@ int clixon_snmp_traverse_mibyangs(clixon_handle h);
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
} /* extern "C" */
|
} /* extern "C" */
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -127,4 +127,3 @@ extern const char CLIXON_VERSION[];
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
} /* extern "C" */
|
} /* extern "C" */
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -35,7 +35,6 @@
|
||||||
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#ifndef _CLIXON_HANDLE_H_
|
#ifndef _CLIXON_HANDLE_H_
|
||||||
#define _CLIXON_HANDLE_H_
|
#define _CLIXON_HANDLE_H_
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -87,6 +87,4 @@ int clixon_logflags_set(uint16_t flags);
|
||||||
int clixon_log_str(int level, char *msg);
|
int clixon_log_str(int level, char *msg);
|
||||||
int clixon_log_fn(clixon_handle h, int user, int level, cxobj *x, const char *format, ...) __attribute__ ((format (printf, 5, 6)));
|
int clixon_log_fn(clixon_handle h, int user, int level, cxobj *x, const char *format, ...) __attribute__ ((format (printf, 5, 6)));
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#endif /* _CLIXON_LOG_H_ */
|
#endif /* _CLIXON_LOG_H_ */
|
||||||
|
|
|
||||||
|
|
@ -46,4 +46,3 @@ int clixon_text_syntax_parse_string(char *str, yang_bind yb, yang_stmt *yspec, c
|
||||||
int clixon_text_syntax_parse_file(FILE *fp, yang_bind yb, yang_stmt *yspec, cxobj **xt, cxobj **xerr);
|
int clixon_text_syntax_parse_file(FILE *fp, yang_bind yb, yang_stmt *yspec, cxobj **xt, cxobj **xerr);
|
||||||
|
|
||||||
#endif /* _CLIXON_TEXT_SYNTAX_H */
|
#endif /* _CLIXON_TEXT_SYNTAX_H */
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -38,7 +38,6 @@
|
||||||
#ifndef _CLIXON_XPATH_OPTIMIZE_H
|
#ifndef _CLIXON_XPATH_OPTIMIZE_H
|
||||||
#define _CLIXON_XPATH_OPTIMIZE_H
|
#define _CLIXON_XPATH_OPTIMIZE_H
|
||||||
|
|
||||||
|
|
||||||
int xpath_list_optimize_stats(int *hits);
|
int xpath_list_optimize_stats(int *hits);
|
||||||
int xpath_list_optimize_set(int enable);
|
int xpath_list_optimize_set(int enable);
|
||||||
void xpath_optimize_exit(void);
|
void xpath_optimize_exit(void);
|
||||||
|
|
|
||||||
|
|
@ -73,5 +73,4 @@ int yang_type_resolve(yang_stmt *yorig, yang_stmt *ys,
|
||||||
uint8_t *fraction);
|
uint8_t *fraction);
|
||||||
enum cv_type yang_type2cv(yang_stmt *ys);
|
enum cv_type yang_type2cv(yang_stmt *ys);
|
||||||
|
|
||||||
|
|
||||||
#endif /* _CLIXON_YANG_TYPE_H_ */
|
#endif /* _CLIXON_YANG_TYPE_H_ */
|
||||||
|
|
|
||||||
|
|
@ -147,4 +147,3 @@ api_path_scan_exit(clixon_api_path_yacc *ay)
|
||||||
clixon_api_path_parselex_destroy(); /* modern */
|
clixon_api_path_parselex_destroy(); /* modern */
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -73,7 +73,6 @@
|
||||||
%type <stack> key_values
|
%type <stack> key_values
|
||||||
%type <stack> key_value
|
%type <stack> key_value
|
||||||
|
|
||||||
|
|
||||||
%lex-param {void *_ay} /* Add this argument to parse() and lex() function */
|
%lex-param {void *_ay} /* Add this argument to parse() and lex() function */
|
||||||
%parse-param {void *_ay}
|
%parse-param {void *_ay}
|
||||||
|
|
||||||
|
|
@ -309,4 +308,3 @@ key_value : STRING { $$ = keyval_set(NULL, $1); free($1); _PARSE_DEBUG("key
|
||||||
;
|
;
|
||||||
|
|
||||||
%%
|
%%
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -35,7 +35,6 @@
|
||||||
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* A simple implementation of a associative array style data store. Keys
|
* A simple implementation of a associative array style data store. Keys
|
||||||
* are always strings while values can be some arbitrary data referenced
|
* are always strings while values can be some arbitrary data referenced
|
||||||
|
|
|
||||||
|
|
@ -153,4 +153,3 @@ instance_id_scan_exit(clixon_instance_id_yacc *iy)
|
||||||
clixon_instance_id_parselex_destroy(); /* modern */
|
clixon_instance_id_parselex_destroy(); /* modern */
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -306,8 +306,6 @@ keyval_set(char *name,
|
||||||
return cv;
|
return cv;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
%}
|
%}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1700,5 +1700,3 @@ clixon_json_parse_file(FILE *fp,
|
||||||
retval = 0;
|
retval = 0;
|
||||||
goto done;
|
goto done;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -139,7 +139,6 @@ hex [A-Fa-f0-9]
|
||||||
|
|
||||||
%%
|
%%
|
||||||
|
|
||||||
|
|
||||||
/*! Initialize scanner.
|
/*! Initialize scanner.
|
||||||
*/
|
*/
|
||||||
int
|
int
|
||||||
|
|
@ -166,4 +165,3 @@ json_scan_exit(clixon_json_yacc *jy)
|
||||||
clixon_json_parselex_destroy(); /* modern */
|
clixon_json_parselex_destroy(); /* modern */
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -333,4 +333,3 @@ number : J_NUMBER { $$ = $1; }
|
||||||
;
|
;
|
||||||
|
|
||||||
%%
|
%%
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1088,7 +1088,6 @@ nacm_datanode_read(clixon_handle h,
|
||||||
return retval;
|
return retval;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/*---------------------------------------------------------------
|
/*---------------------------------------------------------------
|
||||||
* NACM pre-procesing
|
* NACM pre-procesing
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -501,7 +501,6 @@ clixon_pseudo_plugin(clixon_handle h,
|
||||||
return plugin_add_one(h, name, NULL, NULL, cpp);
|
return plugin_add_one(h, name, NULL, NULL, cpp);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/*! Call single plugin start callback
|
/*! Call single plugin start callback
|
||||||
*
|
*
|
||||||
* @param[in] cp Plugin handle
|
* @param[in] cp Plugin handle
|
||||||
|
|
|
||||||
|
|
@ -154,7 +154,6 @@ utf16_literal_to_utf8(const unsigned char *const input, int len,
|
||||||
goto fail;
|
goto fail;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/* calculate the unicode codepoint from the surrogate pair */
|
/* calculate the unicode codepoint from the surrogate pair */
|
||||||
codepoint = 0x10000 + (((first_code & 0x3FF) << 10) | (second_code & 0x3FF));
|
codepoint = 0x10000 + (((first_code & 0x3FF) << 10) | (second_code & 0x3FF));
|
||||||
} else {
|
} else {
|
||||||
|
|
@ -471,4 +470,3 @@ regex_free(clixon_handle h,
|
||||||
done:
|
done:
|
||||||
return retval;
|
return retval;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -713,7 +713,6 @@ stream_notify_xml(clixon_handle h,
|
||||||
return retval;
|
return retval;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/*! Replay a stream by sending notification messages
|
/*! Replay a stream by sending notification messages
|
||||||
*
|
*
|
||||||
* @see RFC5277 Sec 2.1.1:
|
* @see RFC5277 Sec 2.1.1:
|
||||||
|
|
|
||||||
|
|
@ -850,7 +850,6 @@ xml_chardata_decode(char **decp,
|
||||||
return retval;
|
return retval;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/*! Split a string into a cligen variable vector using 1st and 2nd delimiter
|
/*! Split a string into a cligen variable vector using 1st and 2nd delimiter
|
||||||
*
|
*
|
||||||
* (1) Split a string into elements delimited by delim1,
|
* (1) Split a string into elements delimited by delim1,
|
||||||
|
|
|
||||||
|
|
@ -298,4 +298,3 @@ substr : substr TOKEN { _PARSE_DEBUG("substr->substr TOKEN");
|
||||||
;
|
;
|
||||||
|
|
||||||
%%
|
%%
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -761,7 +761,6 @@ choice_mandatory_check(cxobj *xt,
|
||||||
return retval;
|
return retval;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/*! Find yang node which is ancestor of ys (or ys itself) and child of ytop
|
/*! Find yang node which is ancestor of ys (or ys itself) and child of ytop
|
||||||
*
|
*
|
||||||
* Assume tree: ytop ... ys
|
* Assume tree: ytop ... ys
|
||||||
|
|
|
||||||
|
|
@ -2169,7 +2169,6 @@ cxvec_prepend(cxobj *x,
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
/*! Apply a function call recursively on all xml node children recursively
|
/*! Apply a function call recursively on all xml node children recursively
|
||||||
*
|
*
|
||||||
* Recursively traverse all xml nodes in a parse-tree and apply fn(arg) for
|
* Recursively traverse all xml nodes in a parse-tree and apply fn(arg) for
|
||||||
|
|
|
||||||
|
|
@ -123,7 +123,6 @@ xml_parse_content(clixon_xml_yacc *xy,
|
||||||
cxobj *xn = xy->xy_xelement;
|
cxobj *xn = xy->xy_xelement;
|
||||||
cxobj *xp = xy->xy_xparent;
|
cxobj *xp = xy->xy_xparent;
|
||||||
|
|
||||||
|
|
||||||
xy->xy_xelement = NULL; /* init */
|
xy->xy_xelement = NULL; /* init */
|
||||||
if (xn == NULL){
|
if (xn == NULL){
|
||||||
if ((xn = xml_new("body", xp, CX_BODY)) == NULL)
|
if ((xn = xml_new("body", xp, CX_BODY)) == NULL)
|
||||||
|
|
@ -487,7 +486,6 @@ pi : BQMARK NAME EQMARK {_PARSE_DEBUG("pi -> <? NAME ?>"); free($2); }
|
||||||
{ _PARSE_DEBUG("pi -> <? NAME STRING ?>"); free($2); free($3);}
|
{ _PARSE_DEBUG("pi -> <? NAME STRING ?>"); free($2); free($3);}
|
||||||
;
|
;
|
||||||
|
|
||||||
|
|
||||||
attrs : attrs attr { _PARSE_DEBUG("attrs -> attrs attr"); }
|
attrs : attrs attr { _PARSE_DEBUG("attrs -> attrs attr"); }
|
||||||
| { _PARSE_DEBUG("attrs ->"); }
|
| { _PARSE_DEBUG("attrs ->"); }
|
||||||
;
|
;
|
||||||
|
|
|
||||||
|
|
@ -385,4 +385,3 @@ clixon_xvec_print(FILE *f,
|
||||||
return -1;
|
return -1;
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -158,7 +158,6 @@ static const map_str2int axis_type_map[] = {
|
||||||
{NULL, -1}
|
{NULL, -1}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* XPath parse tree type
|
* XPath parse tree type
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -334,4 +334,3 @@ ctx_nodeset_replace(xp_ctx *xc,
|
||||||
xc->xc_size = veclen;
|
xc->xc_size = veclen;
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1451,5 +1451,3 @@ xp_eval(xp_ctx *xc,
|
||||||
ctx_free(xr0);
|
ctx_free(xr0);
|
||||||
return retval;
|
return retval;
|
||||||
} /* xp_eval */
|
} /* xp_eval */
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -158,7 +158,6 @@ xpath_optimize_init(xpath_tree **xm,
|
||||||
return retval;
|
return retval;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/*! Recursive function to loop over all EXPR and pattern match them
|
/*! Recursive function to loop over all EXPR and pattern match them
|
||||||
*
|
*
|
||||||
* @param[in] xt XPath tree of type PRED
|
* @param[in] xt XPath tree of type PRED
|
||||||
|
|
@ -366,4 +365,3 @@ xpath_optimize_check(xpath_tree *xs,
|
||||||
return 0; /* use regular code */
|
return 0; /* use regular code */
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -196,7 +196,6 @@ ncname {namestart}{namechar}*
|
||||||
|
|
||||||
%%
|
%%
|
||||||
|
|
||||||
|
|
||||||
/*! Initialize scanner.
|
/*! Initialize scanner.
|
||||||
*/
|
*/
|
||||||
int
|
int
|
||||||
|
|
@ -223,4 +222,3 @@ xpath_scan_exit(clixon_xpath_yacc *xpy)
|
||||||
clixon_xpath_parselex_destroy(); /* modern */
|
clixon_xpath_parselex_destroy(); /* modern */
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -567,6 +567,4 @@ string : string CHARS {
|
||||||
| CHARS { _PARSE_DEBUG("string-> "); }
|
| CHARS { _PARSE_DEBUG("string-> "); }
|
||||||
;
|
;
|
||||||
|
|
||||||
|
|
||||||
%%
|
%%
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -81,7 +81,6 @@ clixon_yang_parsewrap(void)
|
||||||
Example: keyword argument ; keyword ; keyword { keyword argument; } keyword
|
Example: keyword argument ; keyword ; keyword { keyword argument; } keyword
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
%}
|
%}
|
||||||
|
|
||||||
identifier [A-Za-z_][A-Za-z0-9_\-\.]*
|
identifier [A-Za-z_][A-Za-z0-9_\-\.]*
|
||||||
|
|
@ -110,7 +109,6 @@ identifier [A-Za-z_][A-Za-z0-9_\-\.]*
|
||||||
<KEYWORD,DEVIATE,DEVIATESTR,STRARG,STRING,UNKNOWN,UNKNOWN2>"/*" { _YY->yy_lex_state = YYSTATE; BEGIN(COMMENT1); }
|
<KEYWORD,DEVIATE,DEVIATESTR,STRARG,STRING,UNKNOWN,UNKNOWN2>"/*" { _YY->yy_lex_state = YYSTATE; BEGIN(COMMENT1); }
|
||||||
<KEYWORD,DEVIATE,DEVIATESTR,STRARG,STRING,UNKNOWN,UNKNOWN2>"//" { _YY->yy_lex_state = YYSTATE; BEGIN(COMMENT2); }
|
<KEYWORD,DEVIATE,DEVIATESTR,STRARG,STRING,UNKNOWN,UNKNOWN2>"//" { _YY->yy_lex_state = YYSTATE; BEGIN(COMMENT2); }
|
||||||
|
|
||||||
|
|
||||||
<KEYWORD>input { return K_INPUT; } /* No argument */
|
<KEYWORD>input { return K_INPUT; } /* No argument */
|
||||||
<KEYWORD>output { return K_OUTPUT;} /* No argument */
|
<KEYWORD>output { return K_OUTPUT;} /* No argument */
|
||||||
|
|
||||||
|
|
@ -312,4 +310,3 @@ yang_scan_exit(clixon_yang_yacc *yy)
|
||||||
clixon_yang_parselex_destroy(); /* modern */
|
clixon_yang_parselex_destroy(); /* modern */
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -352,7 +352,6 @@ ysp_add_push(clixon_yang_yacc *yy,
|
||||||
return ys;
|
return ys;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
%}
|
%}
|
||||||
|
|
||||||
%%
|
%%
|
||||||
|
|
@ -500,7 +499,6 @@ include_substmt : revision_date_stmt { _PARSE_DEBUG("include-stmt -> revision-da
|
||||||
| reference_stmt { _PARSE_DEBUG("include-stmt -> reference-stmt"); }
|
| reference_stmt { _PARSE_DEBUG("include-stmt -> reference-stmt"); }
|
||||||
;
|
;
|
||||||
|
|
||||||
|
|
||||||
/* namespace-stmt = namespace-keyword sep uri-str */
|
/* namespace-stmt = namespace-keyword sep uri-str */
|
||||||
namespace_stmt : K_NAMESPACE string stmtend
|
namespace_stmt : K_NAMESPACE string stmtend
|
||||||
{ if (ysp_add(_yy, Y_NAMESPACE, $2, NULL)== NULL) _YYERROR("namespace_stmt");
|
{ if (ysp_add(_yy, Y_NAMESPACE, $2, NULL)== NULL) _YYERROR("namespace_stmt");
|
||||||
|
|
@ -567,7 +565,6 @@ revision_substmt : description_stmt { _PARSE_DEBUG("revision-substmt -> descript
|
||||||
| { _PARSE_DEBUG("revision-substmt -> "); }
|
| { _PARSE_DEBUG("revision-substmt -> "); }
|
||||||
;
|
;
|
||||||
|
|
||||||
|
|
||||||
/* revision */
|
/* revision */
|
||||||
revision_stmts : revision_stmts revision_stmt
|
revision_stmts : revision_stmts revision_stmt
|
||||||
{ _PARSE_DEBUG("revision-stmts -> revision-stmts revision-stmt"); }
|
{ _PARSE_DEBUG("revision-stmts -> revision-stmts revision-stmt"); }
|
||||||
|
|
@ -627,7 +624,6 @@ argument_substmt : yin_element_stmt1 { _PARSE_DEBUG("argument-substmt -> yin-ele
|
||||||
|
|
|
|
||||||
;
|
;
|
||||||
|
|
||||||
|
|
||||||
/* Example of optional rule, eg [yin-element-stmt] */
|
/* Example of optional rule, eg [yin-element-stmt] */
|
||||||
yin_element_stmt1 : K_YIN_ELEMENT bool_str stmtend {free($2);}
|
yin_element_stmt1 : K_YIN_ELEMENT bool_str stmtend {free($2);}
|
||||||
;
|
;
|
||||||
|
|
@ -1061,7 +1057,6 @@ grouping_substmt : status_stmt { _PARSE_DEBUG("grouping-substmt -> status-
|
||||||
| { _PARSE_DEBUG("grouping-substmt -> "); }
|
| { _PARSE_DEBUG("grouping-substmt -> "); }
|
||||||
;
|
;
|
||||||
|
|
||||||
|
|
||||||
/* container */
|
/* container */
|
||||||
container_stmt : K_CONTAINER identifier_str ';'
|
container_stmt : K_CONTAINER identifier_str ';'
|
||||||
{ if (ysp_add(_yy, Y_CONTAINER, $2, NULL) == NULL) _YYERROR("container_stmt");
|
{ if (ysp_add(_yy, Y_CONTAINER, $2, NULL) == NULL) _YYERROR("container_stmt");
|
||||||
|
|
@ -1896,7 +1891,6 @@ bool_str : '"' BOOL '"' { $$ = $2;
|
||||||
_PARSE_DEBUG("bool_str -> BOOL ");}
|
_PARSE_DEBUG("bool_str -> BOOL ");}
|
||||||
;
|
;
|
||||||
|
|
||||||
|
|
||||||
/* ;;; Basic Rules */
|
/* ;;; Basic Rules */
|
||||||
|
|
||||||
/* identifier-ref-arg-str = < a string that matches the rule idenetifier-ref-arg >
|
/* identifier-ref-arg-str = < a string that matches the rule idenetifier-ref-arg >
|
||||||
|
|
|
||||||
|
|
@ -908,7 +908,6 @@ yang_schema_yspec_rm(clixon_handle h,
|
||||||
int retval = -1;
|
int retval = -1;
|
||||||
yang_stmt *yspec = NULL;
|
yang_stmt *yspec = NULL;
|
||||||
char *xpath = NULL;
|
char *xpath = NULL;
|
||||||
|
|
||||||
int ret;
|
int ret;
|
||||||
|
|
||||||
if ((ret = xml_yang_mount_get(h, xmnt, NULL, &xpath, &yspec)) < 0)
|
if ((ret = xml_yang_mount_get(h, xmnt, NULL, &xpath, &yspec)) < 0)
|
||||||
|
|
|
||||||
|
|
@ -197,4 +197,3 @@ identifier : IDENTIFIER
|
||||||
;
|
;
|
||||||
|
|
||||||
%%
|
%%
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -290,4 +290,3 @@ sep1 : sep1 SEP { _PARSE_DEBUG("sep->sep SEP"); }
|
||||||
;
|
;
|
||||||
|
|
||||||
%%
|
%%
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -464,7 +464,6 @@ cv_validate_pattern(clixon_handle h,
|
||||||
((rmin && (i) < cv_##type##_get(rmin)) || \
|
((rmin && (i) < cv_##type##_get(rmin)) || \
|
||||||
(rmax && (i) > cv_##type##_get(rmax)))
|
(rmax && (i) > cv_##type##_get(rmax)))
|
||||||
|
|
||||||
|
|
||||||
/*! Error messsage for int violating ranges
|
/*! Error messsage for int violating ranges
|
||||||
*
|
*
|
||||||
* @note contains kludge - duplicate loop
|
* @note contains kludge - duplicate loop
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue