am 2fa85910: am e0346fa7: am b2a32cb9: am 8fb0caa7: Merge "config_mbr: Fix integer overflow"
* commit '2fa859101f9d5f568c2562b064e233b14973e6fc':
config_mbr: Fix integer overflow
diff --git a/libdiskconfig/config_mbr.c b/libdiskconfig/config_mbr.c
index 703484c..b89d382 100644
--- a/libdiskconfig/config_mbr.c
+++ b/libdiskconfig/config_mbr.c
@@ -152,7 +152,7 @@
/* we are going to write the ebr at the current LBA, and then bump the
* lba counter since that is where the logical data partition will start */
- item->offset = (*lba) * dinfo->sect_size;
+ item->offset = ((loff_t)(*lba)) * dinfo->sect_size;
(*lba)++;
ebr = (struct pc_boot_record *) &item->data;