aboutsummaryrefslogtreecommitdiff
path: root/toys/pending
diff options
context:
space:
mode:
Diffstat (limited to 'toys/pending')
-rw-r--r--toys/pending/mke2fs.c4
-rw-r--r--toys/pending/telnetd.c4
-rw-r--r--toys/pending/traceroute.c3
-rw-r--r--toys/pending/xzcat.c3
4 files changed, 7 insertions, 7 deletions
diff --git a/toys/pending/mke2fs.c b/toys/pending/mke2fs.c
index 19ef5fb0..ee0a5b11 100644
--- a/toys/pending/mke2fs.c
+++ b/toys/pending/mke2fs.c
@@ -546,7 +546,7 @@ void mke2fs_main(void)
{
int i, temp;
off_t length;
- uint32_t usedblocks, usedinodes, dtiblk, dtbblk;
+ uint32_t usedblocks, usedinodes, dtbblk;
struct dirtree *dti, *dtb;
struct ext2_superblock sb;
@@ -634,7 +634,7 @@ void mke2fs_main(void)
put_zeroes(1024);
// Loop through block groups, write out each one.
- dtiblk = dtbblk = usedblocks = usedinodes = 0;
+ dtbblk = usedblocks = usedinodes = 0;
for (i=0; i<TT.groups; i++) {
struct ext2_inode *in = (struct ext2_inode *)toybuf;
uint32_t start, itable, used, end;
diff --git a/toys/pending/telnetd.c b/toys/pending/telnetd.c
index ad39d8c0..bb08e785 100644
--- a/toys/pending/telnetd.c
+++ b/toys/pending/telnetd.c
@@ -119,9 +119,9 @@ static void utmp_entry(void)
setutent(); //start from start
while ((utp_ptr = getutent()) != NULL) {
if (utp_ptr->ut_pid == pid && utp_ptr->ut_type >= INIT_PROCESS) break;
- }
+ }
if (!utp_ptr) entry.ut_type = DEAD_PROCESS;
- time(&entry.ut_time);
+ entry.ut_time = time(0);
setutent();
pututline(&entry);
}
diff --git a/toys/pending/traceroute.c b/toys/pending/traceroute.c
index 1cfdc480..56f8bcf5 100644
--- a/toys/pending/traceroute.c
+++ b/toys/pending/traceroute.c
@@ -477,7 +477,7 @@ static void do_trace()
void traceroute_main(void)
{
- unsigned opt_len = 0, pack_size = 0, tyser = 0;
+ unsigned pack_size = 0, tyser = 0;
int lsrr = 0, set = 1;
if(!(toys.optflags & FLAG_4) &&
@@ -499,7 +499,6 @@ void traceroute_main(void)
resolve_addr(node->arg, AF_INET, SOCK_STREAM, 0, &sin);
TT.gw_list[lsrr] = sin.sin_addr.s_addr;
}
- opt_len = (lsrr + 1) * sizeof(TT.gw_list[0]);
} else TT.first_ttl = 1;
TT.msg_len = pack_size = ICMP_HD_SIZE4; //udp payload is also 8bytes
diff --git a/toys/pending/xzcat.c b/toys/pending/xzcat.c
index 55e0a051..6fdf3428 100644
--- a/toys/pending/xzcat.c
+++ b/toys/pending/xzcat.c
@@ -2570,7 +2570,7 @@ static enum xz_ret dec_block(struct xz_dec *s, struct xz_buf *b)
if (s->check_type == XZ_CHECK_CRC32)
s->crc = xz_crc32(b->out + s->out_start,
b->out_pos - s->out_start, s->crc);
- else if (s->check_type == XZ_CHECK_CRC64)
+ else if (s->check_type == XZ_CHECK_CRC64) {
s->crc = ~(s->crc);
size_t size = b->out_pos - s->out_start;
uint8_t *buf = b->out + s->out_start;
@@ -2579,6 +2579,7 @@ static enum xz_ret dec_block(struct xz_dec *s, struct xz_buf *b)
--size;
}
s->crc=~(s->crc);
+ }
if (ret == XZ_STREAM_END) {
if (s->block_header.compressed != VLI_UNKNOWN