Skip to content

Commit

Permalink
Misc formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
olofhagsand committed Jul 2, 2024
1 parent f42a5ba commit 58358fb
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 14 deletions.
2 changes: 1 addition & 1 deletion lib/clixon/clixon_debug.h
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@
#define CLIXON_DBG_YANG 0x00000020 /* YANG processing */
#define CLIXON_DBG_BACKEND 0x00000040 /* Backend-specific */
#define CLIXON_DBG_CLI 0x00000080 /* CLI frontend */
#define CLIXON_DBG_NETCONF 0x00000100 /* NETCONF frontend */
#define CLIXON_DBG_NETCONF 0x00000100 /* NETCONF frontend/client */
#define CLIXON_DBG_RESTCONF 0x00000200 /* RESTCONF frontend */
#define CLIXON_DBG_SNMP 0x00000400 /* SNMP frontend */
#define CLIXON_DBG_NACM 0x00000800 /* NACM processing */
Expand Down
4 changes: 0 additions & 4 deletions lib/clixon/clixon_xml.h
Original file line number Diff line number Diff line change
Expand Up @@ -282,13 +282,10 @@ cxobj *xml_find_type(cxobj *xn_parent, const char *prefix, const char *name,
char *xml_find_value(cxobj *xn_parent, const char *name);
char *xml_find_body(cxobj *xn, const char *name);
cxobj *xml_find_body_obj(cxobj *xt, const char *name, char *val);

int xml_free(cxobj *xn);

int xml_copy_one(cxobj *xn0, cxobj *xn1);
int xml_copy(cxobj *x0, cxobj *x1);
cxobj *xml_dup(cxobj *x0);

int cxvec_dup(cxobj **vec0, int len0, cxobj ***vec1, int *len1);
int cxvec_append(cxobj *x, cxobj ***vec, int *len);
int cxvec_prepend(cxobj *x, cxobj ***vec, int *len);
Expand All @@ -297,7 +294,6 @@ int xml_apply0(cxobj *xn, enum cxobj_type type, xml_applyfn_t fn, void *ar
int xml_apply_ancestor(cxobj *xn, xml_applyfn_t fn, void *arg);
int xml_isancestor(cxobj *x, cxobj *xp);
cxobj *xml_root(cxobj *xn);

int xml_operation(char *opstr, enum operation_type *op);
char *xml_operation2str(enum operation_type op);
int xml_attr_insert2val(char *instr, enum insert_type *ins);
Expand Down
2 changes: 1 addition & 1 deletion lib/src/clixon_client.c
Original file line number Diff line number Diff line change
Expand Up @@ -402,7 +402,7 @@ clixon_client_connect(clixon_handle h,
goto done;
}

/*! Connect client to clixon backend according to config and return a socket
/*! Disconnect client
*
* @param[in] ch Clixon client session handle
* @retval 0 OK
Expand Down
16 changes: 10 additions & 6 deletions lib/src/clixon_proto.c
Original file line number Diff line number Diff line change
Expand Up @@ -265,10 +265,10 @@ clicon_rpc_connect_unix(clixon_handle h,
* @see clicon_rpc But this is one-shot rpc: open, send, get reply and close.
*/
int
clicon_rpc_connect_inet(clixon_handle h,
char *dst,
uint16_t port,
int *sock0)
clicon_rpc_connect_inet(clixon_handle h,
char *dst,
uint16_t port,
int *sock0)
{
int retval = -1;
int s = -1;
Expand All @@ -290,7 +290,7 @@ clicon_rpc_connect_inet(clixon_handle h,
return -1;
}
if (connect(s, (struct sockaddr*)&addr, sizeof(addr)) < 0){
clixon_err(OE_CFG, errno, "connecting socket inet4");
clixon_err(OE_CFG, errno, "connecting socket inet");
close(s);
goto done;
}
Expand Down Expand Up @@ -651,10 +651,14 @@ clicon_rpc(int sock,
{
int retval = -1;
struct clicon_msg *reply = NULL;
cbuf *cbsend = cbuf_new();
cbuf *cbsend = NULL;
cbuf *cbrcv = NULL;

clixon_debug(CLIXON_DBG_MSG | CLIXON_DBG_DETAIL, "");
if ((cbsend = cbuf_new()) == NULL){
clixon_err(OE_UNIX, errno, "cbuf_new");
goto done;
}
cprintf(cbsend, "%s", msg->op_body);
if (clixon_msg_send11(sock, descr, cbsend) < 0)
goto done;
Expand Down
4 changes: 2 additions & 2 deletions lib/src/clixon_xml_map.c
Original file line number Diff line number Diff line change
Expand Up @@ -571,8 +571,8 @@ xml_diff(cxobj *x0,
* @see text_diff2cbuf Diff buffer in curly
*/
int
xml_tree_equal(cxobj *x0,
cxobj *x1)
xml_tree_equal(cxobj *x0,
cxobj *x1)
{
int retval = 1; /* Not equal */
int eq;
Expand Down

0 comments on commit 58358fb

Please sign in to comment.