#8990: intel partiton addon allows creating partitions > 2TB (easy) ------------------------------------------+---------------------------- Reporter: luroh | Owner: bonefish Type: bug | Status: new Priority: normal | Milestone: R1 Component: Partitioning Systems/Intel | Version: R1/Development Resolution: | Keywords: Blocked By: | Blocking: Has a Patch: 1 | Platform: All ------------------------------------------+---------------------------- Comment (by kushalsingh007): 1.Using {{{partition->Size() / partition->BlockSize() < UINT32_MAX}}} causes the condition to fail. For instance, If BlockSize = 2048 ={{{2^11}}}.Then partition->Size() < {{{2^32}}}*{{{2^11}}} or {{{2^42}}} which is 8TB. Thus clearly the condition fails.Also there can be overflow error using the previous condition. 2.Yeah I assumed the sector size to be 512 which is wrong in some cases. So I think the max limit is {{{UINT32_MAX * SECTOR_SIZE}}}, so how do I get the SectorSize directly? Any suggestions ? 3.I'll make a separate patch for B_BAD_VALUE part and remove the parenthesis. -- Ticket URL: <https://dev.haiku-os.org/ticket/8990#comment:8> Haiku <https://dev.haiku-os.org> Haiku - the operating system.