mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-03 04:01:59 +00:00
lib: make a few log symbols accessible
Might've made a few things too many `static` there. Signed-off-by: David Lamparter <equinox@diac24.net>
This commit is contained in:
parent
5c58f5d336
commit
c6610ea98f
@ -58,7 +58,7 @@ static struct zlog_cfg_filterfile zt_filterfile = {
|
||||
},
|
||||
};
|
||||
|
||||
static const char *zlog_progname;
|
||||
const char *zlog_progname;
|
||||
static const char *zlog_protoname;
|
||||
|
||||
static const struct facility_map {
|
||||
@ -95,7 +95,14 @@ static const char * const zlog_priority[] = {
|
||||
"notifications", "informational", "debugging", NULL,
|
||||
};
|
||||
|
||||
static const char *facility_name(int facility)
|
||||
const char *zlog_priority_str(int priority)
|
||||
{
|
||||
if (priority > LOG_DEBUG)
|
||||
return "???";
|
||||
return zlog_priority[priority];
|
||||
}
|
||||
|
||||
const char *facility_name(int facility)
|
||||
{
|
||||
const struct facility_map *fm;
|
||||
|
||||
@ -105,7 +112,7 @@ static const char *facility_name(int facility)
|
||||
return "";
|
||||
}
|
||||
|
||||
static int facility_match(const char *str)
|
||||
int facility_match(const char *str)
|
||||
{
|
||||
const struct facility_map *fm;
|
||||
|
||||
|
@ -34,6 +34,9 @@ extern void log_config_write(struct vty *vty);
|
||||
extern int log_level_match(const char *s);
|
||||
extern void log_show_syslog(struct vty *vty);
|
||||
|
||||
extern int facility_match(const char *str);
|
||||
extern const char *facility_name(int facility);
|
||||
|
||||
DECLARE_HOOK(zlog_rotate, (), ());
|
||||
extern void zlog_rotate(void);
|
||||
|
||||
|
@ -37,10 +37,13 @@
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
DECLARE_MGROUP(LOG);
|
||||
|
||||
extern char zlog_prefix[];
|
||||
extern size_t zlog_prefixsz;
|
||||
extern int zlog_tmpdirfd;
|
||||
extern int zlog_instance;
|
||||
extern const char *zlog_progname;
|
||||
|
||||
struct xref_logmsg {
|
||||
struct xref xref;
|
||||
@ -274,6 +277,8 @@ extern void zlog_tls_buffer_fini(void);
|
||||
/* Enable or disable 'immediate' output - default is to buffer messages. */
|
||||
extern void zlog_set_immediate(bool set_p);
|
||||
|
||||
extern const char *zlog_priority_str(int priority);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
@ -31,7 +31,6 @@
|
||||
* absolute end.
|
||||
*/
|
||||
|
||||
DECLARE_MGROUP(LOG);
|
||||
DEFINE_MGROUP_ACTIVEATEXIT(LOG, "logging subsystem");
|
||||
|
||||
DEFINE_MTYPE_STATIC(LOG, LOG_FD, "log file target");
|
||||
|
Loading…
Reference in New Issue
Block a user