mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2024-12-25 02:49:32 +03:00
Fix coverity defects: CID 147571, 147574
CID 147571: Unintentional integer overflow (OVERFLOW_BEFORE_WIDEN) CID 147574: Unintentional integer overflow (OVERFLOW_BEFORE_WIDEN) Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: luozhengzheng <luo.zhengzheng@zte.com.cn> Closes #5268
This commit is contained in:
parent
e8d3dcdfb1
commit
05852b3467
@ -409,7 +409,7 @@ dmu_tx_count_dnode(dmu_tx_hold_t *txh)
|
||||
dnode_t *dn = txh->txh_dnode;
|
||||
dnode_t *mdn = DMU_META_DNODE(txh->txh_tx->tx_objset);
|
||||
uint64_t space = mdn->dn_datablksz +
|
||||
((mdn->dn_nlevels-1) << mdn->dn_indblkshift);
|
||||
((uint64_t)(mdn->dn_nlevels-1) << mdn->dn_indblkshift);
|
||||
|
||||
if (dn && dn->dn_dbuf->db_blkptr &&
|
||||
dsl_dataset_block_freeable(dn->dn_objset->os_dsl_dataset,
|
||||
|
@ -5928,7 +5928,7 @@ spa_async_tasks_pending(spa_t *spa)
|
||||
} else {
|
||||
config_task_suspended =
|
||||
(gethrtime() - spa->spa_ccw_fail_time) <
|
||||
(zfs_ccw_retry_interval * NANOSEC);
|
||||
((hrtime_t)zfs_ccw_retry_interval * NANOSEC);
|
||||
}
|
||||
|
||||
return (non_config_tasks || (config_task && !config_task_suspended));
|
||||
|
Loading…
Reference in New Issue
Block a user