Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package snapraid for openSUSE:Factory checked in at 2026-10-12 22:06:53 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/snapraid (Old) and /work/SRC/openSUSE:Factory/.snapraid.new.3698736 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "snapraid" Mon Oct 12 22:06:53 2026 rev:12 rq:1384260 version:14.10 Changes: -------- --- /work/SRC/openSUSE:Factory/snapraid/snapraid.changes 2026-07-21 23:00:39.310235629 +0200 +++ /work/SRC/openSUSE:Factory/.snapraid.new.3698736/snapraid.changes 2026-10-12 22:07:03.144898827 +0200 @@ -1,0 +2,6 @@ +Mon Oct 5 08:41:04 UTC 2026 - Paolo Stivanin <[email protected]> + +- Update to 14.10: + * Enable lock file support on Windows to prevent concurrent runs. + +------------------------------------------------------------------- Old: ---- snapraid-14.9.tar.gz New: ---- snapraid-14.10.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ snapraid.spec ++++++ --- /var/tmp/diff_new_pack.k6LZWF/_old 2026-10-12 22:07:04.056936934 +0200 +++ /var/tmp/diff_new_pack.k6LZWF/_new 2026-10-12 22:07:04.059937060 +0200 @@ -17,7 +17,7 @@ Name: snapraid -Version: 14.9 +Version: 14.10 Release: 0 Summary: Disk array backup for many large rarely-changed files License: GPL-3.0-or-later ++++++ snapraid-14.9.tar.gz -> snapraid-14.10.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/snapraid-14.9/.version new/snapraid-14.10/.version --- old/snapraid-14.9/.version 2026-07-19 17:59:26.000000000 +0200 +++ new/snapraid-14.10/.version 2026-09-23 18:08:27.000000000 +0200 @@ -1 +1 @@ -14.9 \ No newline at end of file +14.10 \ No newline at end of file diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/snapraid-14.9/HISTORY new/snapraid-14.10/HISTORY --- old/snapraid-14.9/HISTORY 2026-07-19 17:56:49.000000000 +0200 +++ new/snapraid-14.10/HISTORY 2026-09-23 18:06:51.000000000 +0200 @@ -1,6 +1,10 @@ SnapRAID HISTORY ================ +14.10 2026/08 +============= + * Enable lock file support on Windows to prevent concurrent runs. + 14.9 2026/07 ============ * Fix a regression when both the '--gui-touch-before' and diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/snapraid-14.9/cmdline/pool.c new/snapraid-14.10/cmdline/pool.c --- old/snapraid-14.9/cmdline/pool.c 2026-07-19 17:56:49.000000000 +0200 +++ new/snapraid-14.10/cmdline/pool.c 2026-09-23 18:06:52.000000000 +0200 @@ -351,7 +351,7 @@ ret = symlink(linkto_exported, path); if (ret != 0) { if (errno == EEXIST) { - log_fatal(errno, "WARNING! Duplicate pooling for '%s'\n", path); + log_error(errno, "WARNING! Duplicate pooling for '%s'\n", path); #ifdef _WIN32 } else if (errno == EPERM) { /* LCOV_EXCL_START */ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/snapraid-14.9/cmdline/portable.h new/snapraid-14.10/cmdline/portable.h --- old/snapraid-14.9/cmdline/portable.h 2026-07-19 17:56:49.000000000 +0200 +++ new/snapraid-14.10/cmdline/portable.h 2026-09-23 18:06:52.000000000 +0200 @@ -231,7 +231,7 @@ /** * Enables lock file support. */ -#if HAVE_FLOCK && HAVE_FTRUNCATE +#if (HAVE_FLOCK && HAVE_FTRUNCATE) || defined(_WIN32) #define HAVE_LOCKFILE 1 #endif diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/snapraid-14.9/cmdline/scan.c new/snapraid-14.10/cmdline/scan.c --- old/snapraid-14.9/cmdline/scan.c 2026-07-19 17:56:49.000000000 +0200 +++ new/snapraid-14.10/cmdline/scan.c 2026-09-23 18:06:52.000000000 +0200 @@ -1822,7 +1822,7 @@ /* if verbose, print the list of duplicates real offsets */ /* other cases are for offsets not supported, so we don't need to report them file by file */ if (phy_last >= FILEPHY_REAL_OFFSET) { - log_error(ESOFT, "WARNING! Files '%s%s' and '%s%s' share the same physical offset %" PRId64 ".\n", disk->dir, phy_file_last->sub, disk->dir, file->sub, phy_last); + log_info(ESOFT, "WARNING! Files '%s%s' and '%s%s' share the same physical offset %" PRId64 ".\n", disk->dir, phy_file_last->sub, disk->dir, file->sub, phy_last); } ++phy_dup; } @@ -1907,7 +1907,7 @@ } } if (done) { - log_fatal(ESOFT, "\nare now missing or have been rewritten!\n"); + log_error(ESOFT, "\nare now missing or have been rewritten!\n"); if (all_rewritten) { log_error(ESOFT, "This could occur when restoring a disk from a backup\n"); log_error(ESOFT, "program that is not setting correctly the timestamps.\n"); @@ -1932,14 +1932,14 @@ if (disk->has_unreliable_physical) { if (!done) { done = 1; - log_error(ESOFT, "WARNING! Physical offsets not supported for disk '%s'", disk->name); + log_info(ESOFT, "WARNING! Physical offsets not supported for disk '%s'", disk->name); } else { - log_error(ESOFT, ", '%s'", disk->name); + log_info(ESOFT, ", '%s'", disk->name); } } } if (done) { - log_error(ESOFT, ". The order of files won't be optimal.\n"); + log_info(ESOFT, ". The order of files won't be optimal.\n"); } } @@ -1951,14 +1951,14 @@ if (disk->has_volatile_inodes) { if (!done) { done = 1; - log_error(ESOFT, "WARNING! Inodes are not persistent for disks: '%s'", disk->name); + log_info(ESOFT, "WARNING! Inodes are not persistent for disks: '%s'", disk->name); } else { - log_error(ESOFT, ", '%s'", disk->name); + log_info(ESOFT, ", '%s'", disk->name); } } } if (done) { - log_error(ESOFT, ". Inodes are not used to detect move operations.\n"); + log_info(ESOFT, ". Inodes are not used to detect move operations.\n"); } /* check for disks with changed UUID */ @@ -2066,7 +2066,7 @@ msg_status("No differences\n"); } if (state->unsynced_blocks != 0) - log_error(EUSER, "The last sync was interrupted. Run it again!\n"); + log_info(EUSER, "The last sync was interrupted. Run it again!\n"); if (state->unsynced_blocks != 0) { log_tag("summary:exit:unsynced\n"); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/snapraid-14.9/cmdline/state.c new/snapraid-14.10/cmdline/state.c --- old/snapraid-14.9/cmdline/state.c 2026-07-19 17:56:49.000000000 +0200 +++ new/snapraid-14.10/cmdline/state.c 2026-09-23 18:06:52.000000000 +0200 @@ -471,11 +471,11 @@ #endif if (state->raid_mode == RAID_MODE_CAUCHY && !state->opt.no_warnings) { if (state->level == 3) { - log_error(ESOFT, "WARNING! Your CPU doesn't have a fast implementation for triple parity.\n"); - log_error(ESOFT, "WARNING! It's recommended to switch to 'z-parity' instead than '3-parity'.\n"); + log_info(EUSER, "WARNING! Your CPU doesn't have a fast implementation for triple parity.\n"); + log_info(EUSER, "WARNING! It's recommended to switch to 'z-parity' instead than '3-parity'.\n"); } else if (state->level > 3) { - log_error(ESOFT, "WARNING! Your CPU doesn't have a fast implementation beyond triple parity.\n"); - log_error(ESOFT, "WARNING! It's recommended to reduce the parity levels to triple parity.\n"); + log_info(EUSER, "WARNING! Your CPU doesn't have a fast implementation beyond triple parity.\n"); + log_info(EUSER, "WARNING! It's recommended to reduce the parity levels to triple parity.\n"); } } @@ -1766,15 +1766,15 @@ if (!state->opt.no_warnings) { /* LCOV_EXCL_START */ if (diskcount >= 36 && state->level < 6) { - log_error(EUSER, "WARNING! For %u disks, it's recommended to use six parity levels.\n", diskcount); + log_info(EUSER, "WARNING! For %u disks, it's recommended to use six parity levels.\n", diskcount); } else if (diskcount >= 29 && state->level < 5) { - log_error(EUSER, "WARNING! For %u disks, it's recommended to use five parity levels.\n", diskcount); + log_info(EUSER, "WARNING! For %u disks, it's recommended to use five parity levels.\n", diskcount); } else if (diskcount >= 22 && state->level < 4) { - log_error(EUSER, "WARNING! For %u disks, it's recommended to use four parity levels.\n", diskcount); + log_info(EUSER, "WARNING! For %u disks, it's recommended to use four parity levels.\n", diskcount); } else if (diskcount >= 15 && state->level < 3) { - log_error(EUSER, "WARNING! For %u disks, it's recommended to use three parity levels.\n", diskcount); + log_info(EUSER, "WARNING! For %u disks, it's recommended to use three parity levels.\n", diskcount); } else if (diskcount >= 5 && state->level < 2) { - log_error(EUSER, "WARNING! For %u disks, it's recommended to use two parity levels.\n", diskcount); + log_info(EUSER, "WARNING! For %u disks, it's recommended to use two parity levels.\n", diskcount); } /* LCOV_EXCL_STOP */ } @@ -2948,7 +2948,7 @@ /* search by UUID if renamed */ disk = find_disk_by_uuid(state, uuid); if (disk) { - log_error(EUSER, "WARNING! Renaming disk '%s' to '%s'\n", buffer, disk->name); + log_info(EUSER, "WARNING! Renaming disk '%s' to '%s'\n", buffer, disk->name); /* write the new state with the new name */ state->need_write = 1; @@ -3169,7 +3169,7 @@ } /* otherwise we can drop it */ - log_error(EUSER, "WARNING! Dropping from '%s' unused split '%u'\n", lev_config_name(v_level), s); + log_info(EUSER, "WARNING! Dropping from '%s' unused split '%u'\n", lev_config_name(v_level), s); } else { char parity_name[64]; @@ -4291,7 +4291,7 @@ /* if not found, assume empty */ if (!f) { - log_error(EUSER, "No content file found. Assuming empty.\n"); + log_info(EUSER, "No content file found. Assuming empty.\n"); /* create the initial mapping */ state_map(state); @@ -4543,7 +4543,7 @@ { tommy_node* i; -#if defined(_linux) /* this sequence is linux specific */ +#if defined(__linux__) /* this sequence is linux specific */ i = tommy_list_head(&state->contentlist); while (i) { struct snapraid_content* content = i->data; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/snapraid-14.9/cmdline/support.c new/snapraid-14.10/cmdline/support.c --- old/snapraid-14.9/cmdline/support.c 2026-07-19 17:56:49.000000000 +0200 +++ new/snapraid-14.10/cmdline/support.c 2026-09-23 18:06:52.000000000 +0200 @@ -418,6 +418,35 @@ unlock_msg(); } + +void log_info(int err, const char* format, ...) +{ + va_list ap; + + lock_msg(); + + if (stdlog) { + if (is_hw(err)) + fprintf(stdlog, "msg:error_hardware: "); /* we never expect an hardware error */ + else + fprintf(stdlog, "msg:info: "); + + va_start(ap, format); + vfprintf(stdlog, format, ap); + va_end(ap); + + fflush(stdlog); + } else { + va_start(ap, format); + vmsg(stderr, format, ap); + va_end(ap); + + fflush(stderr); + } + + unlock_msg(); +} + void log_expected(int err, const char* format, ...) { va_list ap; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/snapraid-14.9/cmdline/support.h new/snapraid-14.10/cmdline/support.h --- old/snapraid-14.9/cmdline/support.h 2026-07-19 17:56:49.000000000 +0200 +++ new/snapraid-14.10/cmdline/support.h 2026-09-23 18:06:52.000000000 +0200 @@ -106,6 +106,15 @@ void log_error(int err, const char* format, ...) __attribute__((format(attribute_printf, 2, 3))); /** + * Informational messages. + * + * Messages reporting general status information or warnings that do not indicate failure. + * + * These messages go in the log file if specified, otherwise they go in stderr. + */ +void log_info(int err, const char* format, ...) __attribute__((format(attribute_printf, 2, 3))); + +/** * Expected error messages, without fallback to stderr. * * These errors are "someway" expected, and then they never go to screen. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/snapraid-14.9/cmdline/util.c new/snapraid-14.10/cmdline/util.c --- old/snapraid-14.9/cmdline/util.c 2026-07-19 17:56:49.000000000 +0200 +++ new/snapraid-14.10/cmdline/util.c 2026-09-23 18:06:52.000000000 +0200 @@ -814,6 +814,34 @@ #if HAVE_LOCKFILE int lock_lock(const char* file) { +#ifdef _WIN32 + wchar_t conv_buf[PATH_MAX]; + HANDLE h; + + if (MultiByteToWideChar(CP_UTF8, 0, file, -1, conv_buf, PATH_MAX) <= 0) { + /* LCOV_EXCL_START */ + errno = EACCES; + return -1; + /* LCOV_EXCL_STOP */ + } + + /* open or create the lock file with zero share mode for exclusive access and delete on close */ + h = CreateFileW(conv_buf, GENERIC_READ | GENERIC_WRITE | DELETE, 0, 0, OPEN_ALWAYS, FILE_ATTRIBUTE_NORMAL | FILE_FLAG_DELETE_ON_CLOSE, 0); + if (h == INVALID_HANDLE_VALUE) { + /* LCOV_EXCL_START */ + DWORD err = GetLastError(); + if (err == ERROR_SHARING_VIOLATION || err == ERROR_ACCESS_DENIED || err == ERROR_DELETE_PENDING) { + errno = EWOULDBLOCK; + } else { + errno = EACCES; + } + return -1; + /* LCOV_EXCL_STOP */ + } + + /* Windows HANDLE values are 31-bit indices into per-process handle tables, so casting to int is safe */ + return (intptr_t)h; +#else int f; f = open(file, O_RDONLY | O_CREAT, 0600); @@ -832,12 +860,21 @@ } return f; +#endif } #endif #if HAVE_LOCKFILE int lock_unlock(int f) { +#ifdef _WIN32 + if (!CloseHandle((HANDLE)(intptr_t)f)) { + /* LCOV_EXCL_START */ + return -1; + /* LCOV_EXCL_STOP */ + } + return 0; +#else /* * Intentionally don't remove the lock file. * Removing it just introduces race course with other process @@ -850,6 +887,7 @@ } return 0; +#endif } #endif diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/snapraid-14.9/configure new/snapraid-14.10/configure --- old/snapraid-14.9/configure 2026-07-19 17:58:12.000000000 +0200 +++ new/snapraid-14.10/configure 2026-09-23 18:07:18.000000000 +0200 @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.72 for SnapRAID CLI 14.9. +# Generated by GNU Autoconf 2.72 for SnapRAID CLI 14.10. # # # Copyright (C) 1992-1996, 1998-2017, 2020-2023 Free Software Foundation, @@ -600,8 +600,8 @@ # Identity of this package. PACKAGE_NAME='SnapRAID CLI' PACKAGE_TARNAME='snapraid' -PACKAGE_VERSION='14.9' -PACKAGE_STRING='SnapRAID CLI 14.9' +PACKAGE_VERSION='14.10' +PACKAGE_STRING='SnapRAID CLI 14.10' PACKAGE_BUGREPORT='' PACKAGE_URL='https://www.snapraid.it' @@ -1336,7 +1336,7 @@ # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -'configure' configures SnapRAID CLI 14.9 to adapt to many kinds of systems. +'configure' configures SnapRAID CLI 14.10 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1407,7 +1407,7 @@ if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of SnapRAID CLI 14.9:";; + short | recursive ) echo "Configuration of SnapRAID CLI 14.10:";; esac cat <<\_ACEOF @@ -1530,7 +1530,7 @@ test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -SnapRAID CLI configure 14.9 +SnapRAID CLI configure 14.10 generated by GNU Autoconf 2.72 Copyright (C) 2023 Free Software Foundation, Inc. @@ -2116,7 +2116,7 @@ This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by SnapRAID CLI $as_me 14.9, which was +It was created by SnapRAID CLI $as_me 14.10, which was generated by GNU Autoconf 2.72. Invocation command line was $ $0$ac_configure_args_raw @@ -3415,7 +3415,7 @@ # Define the identity of the package. PACKAGE='snapraid' - VERSION='14.9' + VERSION='14.10' printf "%s\n" "#define PACKAGE \"$PACKAGE\"" >>confdefs.h @@ -9217,7 +9217,7 @@ # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by SnapRAID CLI $as_me 14.9, which was +This file was extended by SnapRAID CLI $as_me 14.10, which was generated by GNU Autoconf 2.72. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -9282,7 +9282,7 @@ cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config='$ac_cs_config_escaped' ac_cs_version="\\ -SnapRAID CLI config.status 14.9 +SnapRAID CLI config.status 14.10 configured by $0, generated by GNU Autoconf 2.72, with options \\"\$ac_cs_config\\"
