From 142ba5c1b3e73eb4140c972af20d1aa1ca9cbe04 Mon Sep 17 00:00:00 2001 From: Jeremy Kerr Date: Tue, 2 Oct 2012 11:22:37 +0800 Subject: [PATCH] image: use data_size in cert table header Since we write the certificate table starting at data_size (not size), use this value when generating the cert table header. Signed-off-by: Jeremy Kerr --- src/image.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/image.c b/src/image.c index 6072f2d..8f419e7 100644 --- a/src/image.c +++ b/src/image.c @@ -493,7 +493,7 @@ int image_write(struct image *image, const char *filename) /* pad to sizeof(pad)-byte boundary */ padlen = align_up(len, sizeof(pad)) - len; - image->data_dir_sigtable->addr = image->size; + image->data_dir_sigtable->addr = image->data_size; image->data_dir_sigtable->size = len + padlen; } else { image->data_dir_sigtable->addr = 0;