Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package erofs-utils for openSUSE:Factory checked in at 2026-08-13 13:15:09 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/erofs-utils (Old) and /work/SRC/openSUSE:Factory/.erofs-utils.new.17972 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "erofs-utils" Thu Aug 13 13:15:09 2026 rev:20 rq:1370749 version:1.9.3 Changes: -------- --- /work/SRC/openSUSE:Factory/erofs-utils/erofs-utils.changes 2026-07-12 16:20:01.313672715 +0200 +++ /work/SRC/openSUSE:Factory/.erofs-utils.new.17972/erofs-utils.changes 2026-08-13 13:15:11.915720592 +0200 @@ -1,0 +2,11 @@ +Wed Aug 12 04:21:30 UTC 2026 - Jan Engelhardt <[email protected]> + +- Update to release 1.9.3 + * mkfs: Sort inline xattrs for reproducible builds + * mkfs: Fix rebuild mode handling for opaque directories + * mkfs: Fix `--incremental=data` functionality + * mkfs: Fix raw inline handling with `-Eztailpacking` + * mkfs: Harden tar index parsing against invalid sizes + * mkfs: Fix memory leaks for small fragments + +------------------------------------------------------------------- Old: ---- v1.9.2.tar.gz New: ---- v1.9.3.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ erofs-utils.spec ++++++ --- /var/tmp/diff_new_pack.kc4CR3/_old 2026-08-13 13:15:13.119771126 +0200 +++ /var/tmp/diff_new_pack.kc4CR3/_new 2026-08-13 13:15:13.123771294 +0200 @@ -17,7 +17,7 @@ Name: erofs-utils -Version: 1.9.2 +Version: 1.9.3 Release: 0 Summary: Utilities for the Extendable Read-Only Filesystem (EROFS) License: GPL-2.0-or-later ++++++ _scmsync.obsinfo ++++++ --- /var/tmp/diff_new_pack.kc4CR3/_old 2026-08-13 13:15:13.187773980 +0200 +++ /var/tmp/diff_new_pack.kc4CR3/_new 2026-08-13 13:15:13.195774315 +0200 @@ -1,5 +1,5 @@ -mtime: 1783675572 -commit: 6bd5b3d8a22e9ec1e45befefc03f9bbf02b3a431d606e150fd56de200d1ac45a +mtime: 1786508522 +commit: 642fda79f110a757829a7ce145085fd6b54ec02e18e337fd73ed794e4f1796e2 url: https://src.opensuse.org/jengelh/erofs-utils revision: master ++++++ build.specials.obscpio ++++++ ++++++ build.specials.obscpio ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/.gitignore new/.gitignore --- old/.gitignore 1970-01-01 01:00:00.000000000 +0100 +++ new/.gitignore 2026-08-12 06:22:02.000000000 +0200 @@ -0,0 +1 @@ +.osc ++++++ v1.9.2.tar.gz -> v1.9.3.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/erofs-utils-1.9.2/ChangeLog new/erofs-utils-1.9.3/ChangeLog --- old/erofs-utils-1.9.2/ChangeLog 2026-07-01 18:00:00.000000000 +0200 +++ new/erofs-utils-1.9.3/ChangeLog 2026-08-04 18:00:00.000000000 +0200 @@ -1,3 +1,17 @@ +erofs-utils 1.9.3 + +* A quick maintenance release includes the following fixes: + + - (mkfs.erofs) Sort inline xattrs for reproducible builds (Martin Pitt); + - (mkfs.erofs) Fix rebuild mode handling for opaque directories; + - (mkfs.erofs) Fix `--incremental=data` functionality; + - (mkfs.erofs) Fix raw inline handling with `-Eztailpacking` (Yifan Zhao); + - (mkfs.erofs) Harden tar index parsing against invalid sizes; + - (mkfs.erofs) Fix memory leaks for small fragments (Bingwu Zhang); + - Fix various build errors and warnings. + + -- Gao Xiang <[email protected]> Wed, 05 Aug 2026 00:00:00 +0800 + erofs-utils 1.9.2 * This release includes the following updates: diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/erofs-utils-1.9.2/VERSION new/erofs-utils-1.9.3/VERSION --- old/erofs-utils-1.9.2/VERSION 2026-07-01 18:00:00.000000000 +0200 +++ new/erofs-utils-1.9.3/VERSION 2026-08-04 18:00:00.000000000 +0200 @@ -1,2 +1,2 @@ -1.9.2 -2026-07-02 +1.9.3 +2026-08-05 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/erofs-utils-1.9.2/configure.ac new/erofs-utils-1.9.3/configure.ac --- old/erofs-utils-1.9.2/configure.ac 2026-07-01 18:00:00.000000000 +0200 +++ new/erofs-utils-1.9.3/configure.ac 2026-08-04 18:00:00.000000000 +0200 @@ -284,6 +284,7 @@ fallocate getrandom getrlimit + gettid gettimeofday lgetxattr llistxattr diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/erofs-utils-1.9.2/include/erofs/xattr.h new/erofs-utils-1.9.3/include/erofs/xattr.h --- old/erofs-utils-1.9.2/include/erofs/xattr.h 2026-07-01 18:00:00.000000000 +0200 +++ new/erofs-utils-1.9.3/include/erofs/xattr.h 2026-08-04 18:00:00.000000000 +0200 @@ -47,12 +47,14 @@ const void *value, size_t size); int erofs_set_opaque_xattr(struct erofs_inode *inode); void erofs_clear_opaque_xattr(struct erofs_inode *inode); +bool erofs_get_opaque_from_disk(struct erofs_inode *inode); int erofs_set_origin_xattr(struct erofs_inode *inode); int erofs_read_xattrs_from_disk(struct erofs_inode *inode); bool erofs_xattr_prefix_matches(const char *key, unsigned int *index, unsigned int *len); void erofs_xattr_exit(struct erofs_sb_info *sbi); +void erofs_inode_free_xattrs(struct erofs_inode *inode); #ifdef __cplusplus } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/erofs-utils-1.9.2/lib/backends/ublk.c new/erofs-utils-1.9.3/lib/backends/ublk.c --- old/erofs-utils-1.9.2/lib/backends/ublk.c 2026-07-01 18:00:00.000000000 +0200 +++ new/erofs-utils-1.9.3/lib/backends/ublk.c 2026-08-04 18:00:00.000000000 +0200 @@ -29,6 +29,11 @@ #include <liburing.h> #endif +#ifndef HAVE_GETTID +#include <sys/syscall.h> +#define gettid() syscall(__NR_gettid) +#endif + /* (Legacy) Admin commands, issued by ublk server, and handled by ublk driver */ #define UBLK_CMD_GET_QUEUE_AFFINITY 0x01 #define UBLK_CMD_GET_DEV_INFO 0x02 @@ -755,7 +760,10 @@ if (q->dev->stop_efd >= 0) { uint64_t val = 1; - (void)write(q->dev->stop_efd, &val, sizeof(val)); + ret = write(q->dev->stop_efd, &val, sizeof(val)); + if (ret < 0) + erofs_err("failed to write stop event for queue %d: %s", + q->q_id, strerror(errno)); } return NULL; } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/erofs-utils-1.9.2/lib/compress.c new/erofs-utils-1.9.3/lib/compress.c --- old/erofs-utils-1.9.2/lib/compress.c 2026-07-01 18:00:00.000000000 +0200 +++ new/erofs-utils-1.9.3/lib/compress.c 2026-08-04 18:00:00.000000000 +0200 @@ -483,7 +483,8 @@ { inode->z_advise |= Z_EROFS_ADVISE_INLINE_PCLUSTER; inode->idata_size = len; - inode->idata_type = EROFS_IDATA_TYPE_COMPRESSED_DEFAULT; + inode->idata_type = raw ? EROFS_IDATA_TYPE_RAW : + EROFS_IDATA_TYPE_COMPRESSED_DEFAULT; inode->idata = malloc(inode->idata_size); if (!inode->idata) @@ -974,7 +975,8 @@ /* generate compacted_2b */ if (compacted_2b) { - if (!compacted_4b_end && inode->idata_size) + if (!compacted_4b_end && inode->idata_size && + inode->idata_type != EROFS_IDATA_TYPE_RAW) inode->idata_type = EROFS_IDATA_TYPE_COMPRESSED_END_OF_2B; do { in = parse_legacy_indexes(cv, 16, in); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/erofs-utils-1.9.2/lib/fragments.c new/erofs-utils-1.9.3/lib/fragments.c --- old/erofs-utils-1.9.2/lib/fragments.c 2026-07-01 18:00:00.000000000 +0200 +++ new/erofs-utils-1.9.3/lib/fragments.c 2026-08-04 18:00:00.000000000 +0200 @@ -325,6 +325,10 @@ if (fi->pos) { inode->fragmentoff = fi->pos - len; + if (list_empty(&fi->list)) { + free(fi->data); + free(fi); + } return 0; } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/erofs-utils-1.9.2/lib/inode.c new/erofs-utils-1.9.3/lib/inode.c --- old/erofs-utils-1.9.2/lib/inode.c 2026-07-01 18:00:00.000000000 +0200 +++ new/erofs-utils-1.9.3/lib/inode.c 2026-08-04 18:00:00.000000000 +0200 @@ -166,6 +166,7 @@ if (inode->datalayout == EROFS_INODE_CHUNK_BASED) free(inode->chunkindexes); + erofs_inode_free_xattrs(inode); free(inode); return 0; } @@ -1604,7 +1605,8 @@ } /* it will be used in erofs_prepare_inode_buffer */ - if (inode->datalayout == EROFS_INODE_FLAT_INLINE) + if (inode->datalayout == EROFS_INODE_FLAT_INLINE || + inode->datalayout == EROFS_INODE_FLAT_PLAIN) inode->idata_size = inode->i_size & (bsz - 1); /* diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/erofs-utils-1.9.2/lib/rebuild.c new/erofs-utils-1.9.3/lib/rebuild.c --- old/erofs-utils-1.9.2/lib/rebuild.c 2026-07-01 18:00:00.000000000 +0200 +++ new/erofs-utils-1.9.3/lib/rebuild.c 2026-08-04 18:00:00.000000000 +0200 @@ -403,13 +403,15 @@ ret = erofs_read_inode_from_disk(&src); if (ret) goto out; + mergedir = d->inode; if (erofs_inode_is_whiteout(&src)) { - d->inode->opaque = true; + mergedir->opaque = true; goto out; } if (!S_ISDIR(src.i_mode)) goto out; - mergedir = d->inode; + mergedir->opaque |= erofs_get_opaque_from_disk(&src); + erofs_inode_free_xattrs(&src); inode = dir = &src; } else { u64 nid; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/erofs-utils-1.9.2/lib/remotes/oci.c new/erofs-utils-1.9.3/lib/remotes/oci.c --- old/erofs-utils-1.9.2/lib/remotes/oci.c 2026-07-01 18:00:00.000000000 +0200 +++ new/erofs-utils-1.9.3/lib/remotes/oci.c 2026-08-04 18:00:00.000000000 +0200 @@ -1119,6 +1119,8 @@ #define EROFS_OCI_OS "windows" #elif defined(__FreeBSD__) #define EROFS_OCI_OS "freebsd" +#else +#define EROFS_OCI_OS "unknown" #endif #if defined(__x86_64__) || defined(__amd64__) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/erofs-utils-1.9.2/lib/tar.c new/erofs-utils-1.9.3/lib/tar.c --- old/erofs-utils-1.9.2/lib/tar.c 2026-07-01 18:00:00.000000000 +0200 +++ new/erofs-utils-1.9.3/lib/tar.c 2026-08-04 18:00:00.000000000 +0200 @@ -886,6 +886,13 @@ goto invalid_tar; } + if ((s64)st.st_size < 0) { + erofs_err("invalid negative size=%lld @ %lld", + (s64)st.st_size, tar_offset); + ret = -EFSCORRUPTED; + goto out; + } + if (th->typeflag <= '7' && !eh.path) { eh.path = path; j = 0; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/erofs-utils-1.9.2/lib/xattr.c new/erofs-utils-1.9.3/lib/xattr.c --- old/erofs-utils-1.9.2/lib/xattr.c 2026-07-01 18:00:00.000000000 +0200 +++ new/erofs-utils-1.9.3/lib/xattr.c 2026-08-04 18:00:00.000000000 +0200 @@ -400,17 +400,43 @@ return NULL; } +static int erofs_comp_xattritem(const void *a, const void *b) +{ + const struct erofs_xattritem *ia, *ib; + unsigned int la, lb; + int ret; + + ia = *((const struct erofs_xattritem **)a); + ib = *((const struct erofs_xattritem **)b); + la = EROFS_XATTR_KVSIZE(ia->len); + lb = EROFS_XATTR_KVSIZE(ib->len); + + ret = memcmp(ia->kvbuf, ib->kvbuf, min(la, lb)); + if (ret != 0) + return ret; + return cmpsgn(la, lb); +} + static int erofs_inode_xattr_add(struct list_head *hlist, struct erofs_xattritem *item) { - struct erofs_inode_xattr_node *node; + struct erofs_inode_xattr_node *node, *pos; node = malloc(sizeof(*node)); if (!node) return -ENOMEM; init_list_head(&node->list); node->item = item; - list_add(&node->list, hlist); + + /* + * Order each inode's xattrs by name so that images stay reproducible. + * listxattr(2) makes no promise about the order it reports, and + * filesystems disagree: insertion order, on-disk order, or random. + */ + list_for_each_entry(pos, hlist, list) + if (erofs_comp_xattritem(&item, &pos->item) < 0) + break; + list_add_tail(&node->list, &pos->list); return 0; } @@ -576,6 +602,11 @@ erofs_removexattr(inode, OVL_XATTR_OPAQUE); } +bool erofs_get_opaque_from_disk(struct erofs_inode *inode) +{ + return (erofs_getxattr(inode, OVL_XATTR_OPAQUE, NULL, 0) >= 0); +} + int erofs_set_origin_xattr(struct erofs_inode *inode) { return erofs_vfs_setxattr(inode, OVL_XATTR_ORIGIN, NULL, 0); @@ -843,24 +874,6 @@ return count; } -static int comp_shared_xattritem(const void *a, const void *b) -{ - const struct erofs_xattritem *ia, *ib; - unsigned int la, lb; - int ret; - - ia = *((const struct erofs_xattritem **)a); - ib = *((const struct erofs_xattritem **)b); - la = EROFS_XATTR_KVSIZE(ia->len); - lb = EROFS_XATTR_KVSIZE(ib->len); - - ret = memcmp(ia->kvbuf, ib->kvbuf, min(la, lb)); - if (ret != 0) - return ret; - - return la > lb; -} - int erofs_xattr_flush_name_prefixes(struct erofs_importer *im, bool plain) { const struct erofs_importer_params *params = im->params; @@ -1010,7 +1023,7 @@ } DBG_BUGON(i != sharedxattr_count); sorted_n[i] = NULL; - qsort(sorted_n, sharedxattr_count, sizeof(n), comp_shared_xattritem); + qsort(sorted_n, sharedxattr_count, sizeof(n), erofs_comp_xattritem); buf = calloc(1, shared_xattrs_size); if (!buf) { @@ -1091,10 +1104,10 @@ item = node->item; list_del(&node->list); - /* move inline xattrs to the onstack list */ + /* move inline xattrs to the onstack list, order preserved */ if (item->shared_xattr_id < 0 || header->h_shared_count >= UCHAR_MAX) { - list_add(&node->list, &ilst); + list_add_tail(&node->list, &ilst); continue; } @@ -1123,6 +1136,17 @@ return buf; } +void erofs_inode_free_xattrs(struct erofs_inode *inode) +{ + DBG_BUGON(inode->i_count > 0); + + if (erofs_atomic_read(&inode->flags) & EROFS_I_EA_INITED) { + free(inode->xattr_shared_xattrs); + inode->xattr_shared_xattrs = NULL; + inode->xattr_shared_count = 0; + } +} + struct erofs_xattr_iter { struct erofs_sb_info *sbi; struct erofs_buf buf; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/erofs-utils-1.9.2/mkfs/main.c new/erofs-utils-1.9.3/mkfs/main.c --- old/erofs-utils-1.9.2/mkfs/main.c 2026-07-01 18:00:00.000000000 +0200 +++ new/erofs-utils-1.9.3/mkfs/main.c 2026-08-04 18:00:00.000000000 +0200 @@ -1228,7 +1228,7 @@ #endif case 'C': err = erofs_mkfs_strtol(optarg, &endptr, &i, 0); - if (err < 0 || *endptr != '\0' || i <= 0) { + if (err || *endptr != '\0' || i <= 0) { erofs_err("invalid physical clustersize %s", optarg); return -EINVAL; @@ -1250,7 +1250,7 @@ } } err = erofs_mkfs_strtol(optarg, &endptr, &i, 0); - if (err < 0 || (*endptr != '\0' && algid != endptr) || + if (err || (*endptr != '\0' && algid != endptr) || i <= 0) { erofs_err("invalid metabox option %s", optarg); return -EINVAL; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/erofs-utils-1.9.2/mount/main.c new/erofs-utils-1.9.3/mount/main.c --- old/erofs-utils-1.9.2/mount/main.c 2026-07-01 18:00:00.000000000 +0200 +++ new/erofs-utils-1.9.3/mount/main.c 2026-08-04 18:00:00.000000000 +0200 @@ -2026,7 +2026,7 @@ static int erofsmount_fanotify_child(struct erofs_fanotify_ctx *ctx, int pipefd) { - int err; + int err, err2; ctx->fan_fd = erofs_fanotify_init_precontent(); if (ctx->fan_fd < 0) { @@ -2040,7 +2040,9 @@ err = 0; notify: - write(pipefd, &err, sizeof(err)); + err2 = write(pipefd, &err, sizeof(err)); + if (err2 < 0) + erofs_err("failed to notify parent: %s", strerror(errno)); close(pipefd); if (err)
