mirror of
https://gitlab.labs.nic.cz/labs/bird.git
synced 2024-05-11 16:54:54 +00:00
Merge branch 'master' into int-new
This commit is contained in:
@@ -733,7 +733,7 @@ static inline void
|
||||
opaque_format(struct adata *ad, byte *buf, uint size)
|
||||
{
|
||||
byte *bound = buf + size - 10;
|
||||
int i;
|
||||
uint i;
|
||||
|
||||
for(i = 0; i < ad->length; i++)
|
||||
{
|
||||
@@ -776,6 +776,18 @@ ea_show_ec_set(struct cli *c, struct adata *ad, byte *pos, byte *buf, byte *end)
|
||||
}
|
||||
}
|
||||
|
||||
static inline void
|
||||
ea_show_lc_set(struct cli *c, struct adata *ad, byte *pos, byte *buf, byte *end)
|
||||
{
|
||||
int i = lc_set_format(ad, 0, pos, end - pos);
|
||||
cli_printf(c, -1012, "\t%s", buf);
|
||||
while (i)
|
||||
{
|
||||
i = lc_set_format(ad, i, buf, end - buf - 1);
|
||||
cli_printf(c, -1012, "\t\t%s", buf);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* ea_show - print an &eattr to CLI
|
||||
* @c: destination CLI
|
||||
@@ -840,6 +852,9 @@ ea_show(struct cli *c, eattr *e)
|
||||
case EAF_TYPE_EC_SET:
|
||||
ea_show_ec_set(c, ad, pos, buf, end);
|
||||
return;
|
||||
case EAF_TYPE_LC_SET:
|
||||
ea_show_lc_set(c, ad, pos, buf, end);
|
||||
return;
|
||||
case EAF_TYPE_UNDEF:
|
||||
default:
|
||||
bsprintf(pos, "<type %02x>", e->type);
|
||||
|
Reference in New Issue
Block a user