Skip to content

Commit

Permalink
growpart: revert off-by-1 change
Browse files Browse the repository at this point in the history
  • Loading branch information
dermotbradley committed Mar 23, 2022
1 parent ded688f commit 1fad5b1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion bin/growpart
Original file line number Diff line number Diff line change
Expand Up @@ -360,7 +360,7 @@ resize_sfdisk() {
pt_start=$(awk '$1 == pt { print $4 }' "pt=${dpart}" <"${dump_mod}") &&
pt_size=$(awk '$1 == pt { print $6 }' "pt=${dpart}" <"${dump_mod}") &&
[ -n "${pt_start}" -a -n "${pt_size}" ] &&
pt_end=$((${pt_size}+${pt_start}-1)) ||
pt_end=$((${pt_size}+${pt_start})) ||
fail "failed to get start and end for ${dpart} in ${DISK}"

# find the minimal starting location that is >= pt_end
Expand Down

0 comments on commit 1fad5b1

Please sign in to comment.