3.8.0.PRE preparations and

* Obsoleted COMPAT_CLIV and COMPAT_XSL that were optional in 3.7
This commit is contained in:
Olof hagsand 2018-07-22 21:29:21 +02:00
parent f2d2b0a8c0
commit 56e51f1a8d
22 changed files with 29 additions and 1333 deletions

View file

@ -72,7 +72,7 @@ SRC = clixon_sig.c clixon_log.c clixon_err.c clixon_event.c \
clixon_json.c clixon_yang.c clixon_yang_type.c \
clixon_hash.c clixon_options.c clixon_plugin.c \
clixon_proto.c clixon_proto_client.c \
clixon_xsl.c clixon_xpath.c clixon_xpath_ctx.c clixon_sha1.c \
clixon_xpath.c clixon_xpath_ctx.c clixon_sha1.c \
clixon_xml_db.c clixon_netconf_lib.c
YACCOBJS := lex.clixon_xml_parse.o clixon_xml_parse.tab.o \

View file

@ -67,7 +67,6 @@
#include "clixon_options.h"
#include "clixon_xml.h"
#include "clixon_plugin.h"
#include "clixon_xsl.h"
#include "clixon_xpath_ctx.h"
#include "clixon_xpath.h"
#include "clixon_xml_map.h"

View file

@ -71,7 +71,6 @@
#include "clixon_yang.h"
#include "clixon_sig.h"
#include "clixon_xml.h"
#include "clixon_xsl.h"
#include "clixon_proto.h"
static int _atomicio_sig = 0;

View file

@ -64,7 +64,6 @@
#include "clixon_options.h"
#include "clixon_xml.h"
#include "clixon_plugin.h"
#include "clixon_xsl.h"
#include "clixon_string.h"
#include "clixon_xpath_ctx.h"
#include "clixon_xpath.h"

View file

@ -85,7 +85,6 @@
#include "clixon_plugin.h"
#include "clixon_xpath_ctx.h"
#include "clixon_xpath.h"
#include "clixon_xsl.h"
#include "clixon_log.h"
#include "clixon_err.h"
#include "clixon_xml_sort.h"
@ -1088,13 +1087,7 @@ api_path_fmt2xpath(char *api_path_fmt,
clicon_err(OE_UNIX, errno, "cv2str_dup");
goto done;
}
cprintf(cb,
#ifdef COMPAT_XSL
"[%s=%s]",
#else
"[%s='%s']",
#endif
cv_name_get(cv), str);
cprintf(cb, "[%s='%s']", cv_name_get(cv), str);
free(str);
}
}
@ -1511,13 +1504,7 @@ api_path2xpath_cvv(yang_spec *yspec,
cprintf(xpath, "/%s", name);
v = val;
while ((cvi = cvec_each(cvk, cvi)) != NULL){
cprintf(xpath,
#ifdef COMPAT_XSL
"[%s=%s]",
#else
"[%s='%s']",
#endif
cv_string_get(cvi), v);
cprintf(xpath, "[%s='%s']", cv_string_get(cvi), v);
v += strlen(v)+1;
}
if (val)

View file

@ -62,7 +62,6 @@
#include "clixon_handle.h"
#include "clixon_yang.h"
#include "clixon_xml.h"
#include "clixon_xsl.h"
#include "clixon_xpath_parse.h"
#include "clixon_xpath_ctx.h"
#include "clixon_xpath.h"
@ -1142,16 +1141,11 @@ xpath_first(cxobj *xcur,
goto done;
}
va_end(ap);
#ifdef COMPAT_XSL
if ((cx = xpath_first_xsl(xcur, xpath)) == NULL)
goto done;
#else
if (xpath_vec_ctx(xcur, xpath, &xr) < 0)
goto done;
if (xr && xr->xc_type == XT_NODESET && xr->xc_size)
cx = xr->xc_nodeset[0];
#endif
done:
if (xr)
ctx_free(xr);
@ -1211,10 +1205,6 @@ xpath_vec(cxobj *xcur,
va_end(ap);
*vec=NULL;
*veclen = 0;
#ifdef COMPAT_XSL
if (xpath_vec_xsl(xcur, xpath, vec, veclen) < 0)
goto done;
#else
if (xpath_vec_ctx(xcur, xpath, &xr) < 0)
goto done;
if (xr && xr->xc_type == XT_NODESET){
@ -1222,7 +1212,6 @@ xpath_vec(cxobj *xcur,
xr->xc_nodeset = NULL;
*veclen = xr->xc_size;
}
#endif
retval = 0;
done:
if (xr)
@ -1268,10 +1257,8 @@ xpath_vec_flag(cxobj *xcur,
size_t len;
char *xpath = NULL;
xp_ctx *xr = NULL;
#ifndef COMPAT_XSL
int i;
cxobj *x;
#endif
va_start(ap, veclen);
len = vsnprintf(NULL, 0, format, ap);
@ -1291,10 +1278,6 @@ xpath_vec_flag(cxobj *xcur,
va_end(ap);
*vec=NULL;
*veclen = 0;
#ifdef COMPAT_XSL
if (xpath_vec_flag_xsl(xcur, xpath, flags, vec, veclen) < 0)
goto done;
#else
if (xpath_vec_ctx(xcur, xpath, &xr) < 0)
goto done;
if (xr && xr->xc_type == XT_NODESET){
@ -1305,8 +1288,6 @@ xpath_vec_flag(cxobj *xcur,
goto done;
}
}
#endif
retval = 0;
done:
if (xr)

File diff suppressed because it is too large Load diff