From: Christoph Hellwig Date: Fri, 28 Nov 2025 06:29:59 +0000 (+0100) Subject: logprint: cleanup xlog_reallocate_xhdrs X-Git-Tag: v6.18.0~50 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=6bcb161d223352400c63217803b597b147d1db4c;p=xfsprogs-dev.git logprint: cleanup xlog_reallocate_xhdrs Re-indent and drop typedefs. Signed-off-by: Christoph Hellwig Reviewed-by: Andrey Albershteyn --- diff --git a/logprint/log_misc.c b/logprint/log_misc.c index 2985429d..2fff434b 100644 --- a/logprint/log_misc.c +++ b/logprint/log_misc.c @@ -1321,11 +1321,15 @@ print_xlog_bad_reqd_hdrs( } static void -xlog_reallocate_xhdrs(int num_hdrs, xlog_rec_ext_header_t **ret_xhdrs) +xlog_reallocate_xhdrs( + int num_hdrs, + struct xlog_rec_ext_header **ret_xhdrs) { - int len = (num_hdrs-1) * sizeof(xlog_rec_ext_header_t); + int len; - *ret_xhdrs = (xlog_rec_ext_header_t *)realloc(*ret_xhdrs, len); + len = (num_hdrs - 1) * sizeof(struct xlog_rec_ext_header); + + *ret_xhdrs = realloc(*ret_xhdrs, len); if (*ret_xhdrs == NULL) { fprintf(stderr, _("%s: xlog_print: malloc failed for ext hdrs\n"), progname); exit(1);