Replace "(unsigned long) -1L" with -1UL
* defs.h (dumpiov): Replace "(unsigned long) -1L" with -1UL. * io.c (print_iovec, tprint_iov): Likewise. * msghdr.c (SYS_FUNC(sendmsg)): Likewise. * syscall.c (dumpio): Likewise. * poll.c (decode_poll_exiting): Replace "(unsigned int) -1" with -1U.
This commit is contained in:
parent
ee75f4e926
commit
f0ba3723f5
2
defs.h
2
defs.h
@ -592,7 +592,7 @@ extern void dumpiov_in_msghdr(struct tcb *, long, unsigned long);
|
||||
extern void dumpiov_in_mmsghdr(struct tcb *, long);
|
||||
extern void dumpiov_upto(struct tcb *, int, long, unsigned long);
|
||||
#define dumpiov(tcp, len, addr) \
|
||||
dumpiov_upto((tcp), (len), (addr), (unsigned long) -1L)
|
||||
dumpiov_upto((tcp), (len), (addr), -1UL)
|
||||
extern void dumpstr(struct tcb *, long, int);
|
||||
extern void printstr_ex(struct tcb *, long addr, long len,
|
||||
unsigned int user_style);
|
||||
|
6
io.c
6
io.c
@ -85,14 +85,14 @@ print_iovec(struct tcb *tcp, void *elem_buf, size_t elem_size, void *data)
|
||||
case IOV_DECODE_STR:
|
||||
if (len > c->data_size)
|
||||
len = c->data_size;
|
||||
if (c->data_size != (unsigned long) -1L)
|
||||
if (c->data_size != -1UL)
|
||||
c->data_size -= len;
|
||||
printstr(tcp, iov[0], len);
|
||||
break;
|
||||
case IOV_DECODE_NETLINK:
|
||||
if (len > c->data_size)
|
||||
len = c->data_size;
|
||||
if (c->data_size != (unsigned long) -1L)
|
||||
if (c->data_size != -1UL)
|
||||
c->data_size -= len;
|
||||
decode_netlink(tcp, iov[0], iov[1]);
|
||||
break;
|
||||
@ -126,7 +126,7 @@ void
|
||||
tprint_iov(struct tcb *tcp, unsigned long len, unsigned long addr,
|
||||
enum iov_decode decode_iov)
|
||||
{
|
||||
tprint_iov_upto(tcp, len, addr, decode_iov, (unsigned long) -1L);
|
||||
tprint_iov_upto(tcp, len, addr, decode_iov, -1UL);
|
||||
}
|
||||
|
||||
SYS_FUNC(readv)
|
||||
|
2
msghdr.c
2
msghdr.c
@ -402,7 +402,7 @@ SYS_FUNC(sendmsg)
|
||||
{
|
||||
printfd(tcp, tcp->u_arg[0]);
|
||||
tprints(", ");
|
||||
decode_msghdr(tcp, 0, tcp->u_arg[1], (unsigned long) -1L);
|
||||
decode_msghdr(tcp, 0, tcp->u_arg[1], -1UL);
|
||||
/* flags */
|
||||
tprints(", ");
|
||||
printflags(msg_flags, tcp->u_arg[2], "MSG_???");
|
||||
|
2
poll.c
2
poll.c
@ -68,7 +68,7 @@ decode_poll_exiting(struct tcb *tcp, const long pts)
|
||||
const unsigned long start = tcp->u_arg[0];
|
||||
const unsigned long end = start + size;
|
||||
const unsigned long max_printed =
|
||||
abbrev(tcp) ? max_strlen : (unsigned int) -1;
|
||||
abbrev(tcp) ? max_strlen : -1U;
|
||||
unsigned long printed, cur;
|
||||
|
||||
static char outstr[1024];
|
||||
|
@ -478,8 +478,7 @@ dumpio(struct tcb *tcp)
|
||||
dumpiov(tcp, tcp->u_arg[2], tcp->u_arg[1]);
|
||||
break;
|
||||
case SEN_sendmsg:
|
||||
dumpiov_in_msghdr(tcp, tcp->u_arg[1],
|
||||
(unsigned long) -1L);
|
||||
dumpiov_in_msghdr(tcp, tcp->u_arg[1], -1UL);
|
||||
break;
|
||||
case SEN_sendmmsg:
|
||||
dumpiov_in_mmsghdr(tcp, tcp->u_arg[1]);
|
||||
|
Loading…
x
Reference in New Issue
Block a user