xua: Remove library-internal DXUA log subsystem

We don't really need those thre log messages, and we can thus do away
with the library-internal log-subsystem of DXUA.  The rest of
libosmo-sigtran uses the new globa DL... subsystems anyway

Change-Id: Iea0d3db34a3674a9c6422b174a879bfdaa25786f
This commit is contained in:
Harald Welte 2017-04-03 22:16:13 +02:00
parent 996defec17
commit 4881c5c169
2 changed files with 2 additions and 18 deletions

View File

@ -69,8 +69,6 @@ struct xua_msg_event_map {
extern const struct xua_dialect xua_dialect_sua;
extern const struct xua_dialect xua_dialect_m3ua;
extern int DXUA;
struct xua_msg *xua_msg_alloc(void);
void xua_msg_free(struct xua_msg *msg);
@ -84,8 +82,6 @@ int xua_msg_copy_part(struct xua_msg *xua_out, uint16_t tag_out,
struct xua_msg *xua_from_msg(const int version, uint16_t len, uint8_t *data);
struct msgb *xua_to_msg(const int version, struct xua_msg *msg);
void xua_set_log_area(int log_area);
int msgb_t16l16vp_put(struct msgb *msg, uint16_t tag, uint16_t len, const uint8_t *data);
int msgb_t16l16vp_put_u32(struct msgb *msg, uint16_t tag, uint32_t val);
int xua_msg_add_u32(struct xua_msg *xua, uint16_t iei, uint32_t val);

View File

@ -32,17 +32,14 @@
#include <errno.h>
static void *tall_xua;
int DXUA = -1;
struct xua_msg *xua_msg_alloc(void)
{
struct xua_msg *msg;
msg = talloc_zero(tall_xua, struct xua_msg);
if (!msg) {
LOGP(DXUA, LOGL_ERROR, "Failed to allocate.\n");
if (!msg)
return NULL;
}
INIT_LLIST_HEAD(&msg->headers);
return msg;
@ -162,7 +159,6 @@ struct xua_msg *xua_from_msg(const int version, uint16_t len, uint8_t *data)
return msg;
fail:
LOGP(DXUA, LOGL_ERROR, "Failed to parse.\n");
xua_msg_free(msg);
return NULL;
}
@ -175,10 +171,8 @@ struct msgb *xua_to_msg(const int version, struct xua_msg *xua)
uint8_t rest;
msg = msgb_alloc_headroom(2048, 512, "xua msg");
if (!msg) {
LOGP(DXUA, LOGL_ERROR, "Failed to allocate.\n");
if (!msg)
return NULL;
}
msg->l2h = msgb_put(msg, sizeof(*hdr));
hdr = (struct xua_common_hdr *) msg->l2h;
@ -209,12 +203,6 @@ struct msgb *xua_to_msg(const int version, struct xua_msg *xua)
return msg;
}
void xua_set_log_area(int log_area)
{
DXUA = log_area;
}
/***********************************************************************
* Message encoding helper functions
***********************************************************************/