mirror of
https://git.FreeBSD.org/src.git
synced 2025-01-17 15:27:36 +00:00
This commit was generated by cvs2svn to compensate for changes in r124488,
which included commits to RCS files with non-trunk default branches.
This commit is contained in:
commit
cea4bb1622
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=124489
@ -332,9 +332,13 @@ rawprint(caddr_t loc, size_t len)
|
||||
static u_char *p;
|
||||
int i;
|
||||
|
||||
TCHECK2(*loc, len);
|
||||
|
||||
p = (u_char *)loc;
|
||||
for (i = 0; i < len; i++)
|
||||
printf("%02x", p[i] & 0xff);
|
||||
trunc:
|
||||
|
||||
}
|
||||
|
||||
struct attrmap {
|
||||
@ -1060,6 +1064,8 @@ isakmp_sub_print(u_char np, struct isakmp_gen *ext, u_char *ep,
|
||||
cp = (u_char *)ext;
|
||||
|
||||
while (np) {
|
||||
TCHECK2(*ext, sizeof(e));
|
||||
|
||||
safememcpy(&e, ext, sizeof(e));
|
||||
|
||||
if (ep < (u_char *)ext + ntohs(e.len)) {
|
||||
@ -1085,6 +1091,8 @@ isakmp_sub_print(u_char np, struct isakmp_gen *ext, u_char *ep,
|
||||
ext = (struct isakmp_gen *)cp;
|
||||
}
|
||||
return cp;
|
||||
trunc:
|
||||
return NULL;
|
||||
}
|
||||
|
||||
static char *
|
||||
|
@ -473,7 +473,7 @@ print_attr_string(register u_char *data, u_int length, u_short attr_code )
|
||||
break;
|
||||
}
|
||||
|
||||
for (i=0; i < length ; i++, data++)
|
||||
for (i=0; *data && i < length ; i++, data++)
|
||||
printf("%c",(*data < 32 || *data > 128) ? '.' : *data );
|
||||
|
||||
printf("}");
|
||||
|
Loading…
Reference in New Issue
Block a user