commit - a88ae11ea0ac4b98bc3140a8882e488c6151cbdc
commit + f977c8f406a98059de67ababf2eda345f5c25464
blob - 65528dfcddfcb1e5160d0d81a46d39cbd679df7b
blob + 5a3034039510580aaa16886bd6666d1303af8a98
--- lsblk.c
+++ lsblk.c
struct disklabel label;
char *ppath, *letter;
- bzero (disk, sizeof *disk);
+ memset (disk, 0, sizeof *disk);
{ // Read disklabel.
size_t len;
const struct statfs *mnt;
struct my_partinfo part;
- bzero (&part, sizeof part);
+ memset (&part, 0, sizeof part);
part.size = DL_GETPSIZE (p) * label.d_secsize;
return;
}
- bzero (&bi, sizeof bi);
+ memset (&bi, 0, sizeof bi);
if (ioctl (fd, BIOCINQ, &bi) == -1)
goto ret;
for (int i = 0; i < bi.bi_novol; ++i) {
struct bioc_vol bv;
- bzero (&bv, sizeof bv);
+ memset (&bv, 0, sizeof bv);
memcpy (&bv.bv_bio, &bi.bi_bio, sizeof bi.bi_bio);
bv.bv_volid = i;
size_t len_vendor;
char letter;
- bzero (&bd, sizeof bd);
+ memset (&bd, 0, sizeof bd);
memcpy (&bd.bd_bio, &bi.bi_bio, sizeof bi.bi_bio);
bd.bd_volid = i;
bd.bd_diskid = j;