This is an automated email from the git hooks/post-receive script.
andyp pushed a commit to branch master in repository gfs2-utils.
commit 4cb82588eb104c4649404d0fe999b5c92bcf24a9 Author: Andrew Price anprice@redhat.com Date: Thu Aug 17 17:57:34 2017 +0100
gfs2_edit savemeta: Use size_t for saved structure lengths
Although the value range can fit in an int it's better to use an unsigned type consistent with sizeof and memcpy.
Signed-off-by: Andrew Price anprice@redhat.com --- gfs2/edit/savemeta.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/gfs2/edit/savemeta.c b/gfs2/edit/savemeta.c index 04f67fc..664484f 100644 --- a/gfs2/edit/savemeta.c +++ b/gfs2/edit/savemeta.c @@ -190,11 +190,11 @@ static const char *anthropomorphize(unsigned long long inhuman_value) return out_val; }
-static int di_save_len(struct gfs2_buffer_head *bh, uint64_t owner) +static size_t di_save_len(struct gfs2_buffer_head *bh, uint64_t owner) { struct gfs2_inode *inode; struct gfs2_dinode *dn; - int len; + size_t len;
if (sbd.gfs1) inode = lgfs2_gfs_inode_get(&sbd, bh); @@ -234,7 +234,7 @@ static int di_save_len(struct gfs2_buffer_head *bh, uint64_t owner) * -1 if this isn't gfs metadata. */ static int get_gfs_struct_info(struct gfs2_buffer_head *lbh, uint64_t owner, - int *block_type, int *gstruct_len) + int *block_type, size_t *gstruct_len) { struct gfs2_meta_header mh;
@@ -423,8 +423,8 @@ static int savemetaclose(struct metafd *mfd) static int save_bh(struct metafd *mfd, struct gfs2_buffer_head *savebh, uint64_t owner, int *blktype) { struct saved_metablock *savedata; + size_t blklen; size_t outsz; - int blklen;
/* If this isn't metadata and isn't a system file, we don't want it. Note that we're checking "owner" here rather than blk. That's
cluster-commits@lists.stg.fedorahosted.org