cgpt: Fix error in modifying size of an existing partition

Modifying the size of an existing partition without modifying the start as
well assumed the start was at block 0. Sometimes it was caught, often it
wasn't.

Fix the error, add a test to catch the problem.

BUG=chrome-os-partner:13090
BRANCH=all
TEST=manual

make && make runtests

Change-Id: I4f5a5031a90a3e78d886ed3573f61305316a3f1f
Signed-off-by: Bill Richardson <wfrichar@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/31418
Reviewed-by: Randall Spangler <rspangler@chromium.org>
2 files changed