mirror of
https://github.com/hak5/wifipineapple-openwrt.git
synced 2025-10-29 16:57:19 +00:00
fix cylinder rounding in ptgen
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@6352 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
parent
f06ef1e706
commit
ccc7465f7a
@ -114,7 +114,7 @@ static void to_chs(long sect, unsigned char chs[3]) {
|
||||
static inline unsigned long round_to_cyl(long sect) {
|
||||
int cyl_size = heads * sectors;
|
||||
|
||||
return sect + cyl_size - ((sect % cyl_size) ?: cyl_size);
|
||||
return sect + cyl_size - (sect % cyl_size);
|
||||
}
|
||||
|
||||
/* check the partition sizes and write the partition table */
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user