-/* allocate space for the following string
- * xxxx.xxxx.xxxx
- * 14 bytes plus one termination byte */
-static char *
-isis_print_sysid(const u_int8_t *cp, int sysid_len)
-{
- int i;
- static char sysid[15];
- char *pos = sysid;
-
- for (i = 1; i <= sysid_len; i++) {
- if (!TTEST2(*cp, 1))
- return (0);
- sprintf(pos, "%02x", *cp++);
- pos += strlen(pos);
- if ((i==2)^(i==4)) {
- *pos++ = '.';
- }
- }
- *(pos) = '\0';
- return (sysid);
-}
-
-
-/* allocate space for the following string
- * xxxx.xxxx.xxxx.yy
- * 17 bytes plus one termination byte */
-static char *
-isis_print_nodeid(const u_int8_t *cp)
-{
- int i;
- static char nodeid[18];
- char *pos = nodeid;
-
- for (i = 1; i <= 7; i++) {
- if (!TTEST2(*cp, 1))
- return (0);
- sprintf(pos, "%02x", *cp++);
- pos += strlen(pos);
- if ((i & 1) == 0) {
- *pos++ = '.';
- }
- }
- *(pos) = '\0';
- return (nodeid);
-}
-
-/* allocate space for the following string
+/* shared routine for printing system, node and lsp-ids
+ * allocate space for the worst-case string