@@ -263,16 +263,6 @@ static char *l2tp_error_code_general[] = {
263
263
/******************************/
264
264
/* generic print out routines */
265
265
/******************************/
266
- static void
267
- print_string (netdissect_options * ndo , const u_char * dat , u_int length )
268
- {
269
- u_int i ;
270
- for (i = 0 ; i < length ; i ++ ) {
271
- fn_print_char (ndo , GET_U_1 (dat ));
272
- dat ++ ;
273
- }
274
- }
275
-
276
266
static void
277
267
print_octets (netdissect_options * ndo , const u_char * dat , u_int length )
278
268
{
@@ -336,7 +326,7 @@ l2tp_result_code_print(netdissect_options *ndo, const u_char *dat, u_int length)
336
326
if (length == 0 )
337
327
return ;
338
328
ND_PRINT (" " );
339
- print_string (ndo , dat , length );
329
+ nd_printjn (ndo , dat , length );
340
330
}
341
331
342
332
static void
@@ -393,7 +383,7 @@ l2tp_q931_cc_print(netdissect_options *ndo, const u_char *dat, u_int length)
393
383
length -= 3 ;
394
384
if (length != 0 ) {
395
385
ND_PRINT (" " );
396
- print_string (ndo , dat , length );
386
+ nd_printjn (ndo , dat , length );
397
387
}
398
388
}
399
389
@@ -559,7 +549,7 @@ l2tp_ppp_discon_cc_print(netdissect_options *ndo, const u_char *dat, u_int lengt
559
549
560
550
if (length != 0 ) {
561
551
ND_PRINT (" " );
562
- print_string (ndo , (const u_char * )dat , length );
552
+ nd_printjn (ndo , (const u_char * )dat , length );
563
553
}
564
554
}
565
555
@@ -659,7 +649,7 @@ l2tp_avp_print(netdissect_options *ndo, const u_char *dat, u_int length)
659
649
case L2TP_AVP_SUB_ADDRESS :
660
650
case L2TP_AVP_PROXY_AUTH_NAME :
661
651
case L2TP_AVP_PRIVATE_GRP_ID :
662
- print_string (ndo , dat , len - 6 );
652
+ nd_printjn (ndo , dat , len - 6 );
663
653
break ;
664
654
case L2TP_AVP_CHALLENGE :
665
655
case L2TP_AVP_INI_RECV_LCP :
0 commit comments