diff -Nru cronutils-1.9/debian/changelog cronutils-1.10/debian/changelog --- cronutils-1.9/debian/changelog 2021-10-12 03:08:52.000000000 +0000 +++ cronutils-1.10/debian/changelog 2023-08-18 03:23:02.000000000 +0000 @@ -1,3 +1,16 @@ +cronutils (1.10-1) unstable; urgency=medium + + [ Jamie Wilkinson ] + * New upstream release. + + [ Debian Janitor ] + * Set upstream metadata fields: Bug-Database, Bug-Submit. + * Update standards version to 4.6.0, no changes needed. + * Avoid explicitly specifying -Wl,--as-needed linker flag. + * Remove constraints unnecessary since buster (oldstable) + + -- Jamie Wilkinson Fri, 18 Aug 2023 13:23:02 +1000 + cronutils (1.9-3) unstable; urgency=medium * Fix case of Vcs-* fields in control. diff -Nru cronutils-1.9/debian/control cronutils-1.10/debian/control --- cronutils-1.9/debian/control 2021-10-08 00:13:13.000000000 +0000 +++ cronutils-1.10/debian/control 2023-08-18 03:20:10.000000000 +0000 @@ -2,8 +2,8 @@ Section: admin Priority: optional Maintainer: Jamie Wilkinson -Build-Depends: debhelper-compat (= 13), dpkg-dev (>= 1.16.1~) -Standards-Version: 4.5.1 +Build-Depends: debhelper-compat (= 13) +Standards-Version: 4.6.0 Homepage: https://github.com/google/cronutils Vcs-Browser: https://salsa.debian.org/debian/cronutils Vcs-Git: https://salsa.debian.org/debian/cronutils.git diff -Nru cronutils-1.9/debian/patches/debian-changes cronutils-1.10/debian/patches/debian-changes --- cronutils-1.9/debian/patches/debian-changes 2021-10-12 03:08:52.000000000 +0000 +++ cronutils-1.10/debian/patches/debian-changes 1970-01-01 00:00:00.000000000 +0000 @@ -1,27 +0,0 @@ -This is an autogenerated patch header for a single-debian-patch file. The -delta against upstream is either kept as a single patch, or maintained -in some VCS, and exported as a single patch instead of more manageable -atomic patches. - ---- cronutils-1.9.orig/runlock.1 -+++ cronutils-1.9/runlock.1 -@@ -16,7 +16,7 @@ runlock \- prevent concurrent execution - \fBrunlock\fR tries to hold an exclusive lock while it executes a - command. Subsequent execution of \fBrunlock\fR with the same lock, - while that lock is held, will cause the new instance of \fBrunlock\fR --to terminate with a faliure exit code. Otherwise, the exit code of the -+to terminate with a failure exit code. Otherwise, the exit code of the - subprocess is returned. - - .SH USAGE ---- cronutils-1.9.orig/subprocess.c -+++ cronutils-1.9/subprocess.c -@@ -129,7 +129,7 @@ int run_subprocess(char * command, char - alarm(0); - if (pid > 0) { - if (pid != childpid) { -- syslog(LOG_ERR, "childpid %d not retured by waitpid! instead %d", -+ syslog(LOG_ERR, "childpid %d not returned by waitpid! instead %d", - childpid, pid); - kill_process_group(); - exit(EX_OSERR); diff -Nru cronutils-1.9/debian/patches/series cronutils-1.10/debian/patches/series --- cronutils-1.9/debian/patches/series 2021-02-10 04:43:17.000000000 +0000 +++ cronutils-1.10/debian/patches/series 1970-01-01 00:00:00.000000000 +0000 @@ -1 +0,0 @@ -debian-changes diff -Nru cronutils-1.9/debian/rules cronutils-1.10/debian/rules --- cronutils-1.9/debian/rules 2015-03-14 10:59:18.000000000 +0000 +++ cronutils-1.10/debian/rules 2023-08-18 03:20:10.000000000 +0000 @@ -10,7 +10,6 @@ #export DH_VERBOSE=1 export DEB_BUILD_MAINT_OPTIONS = hardening=+all export DEB_CFLAGS_MAINT_APPEND = -Wall -pedantic -export DEB_LDFLAGS_MAINT_APPEND = -Wl,--as-needed %: dh $@ diff -Nru cronutils-1.9/debian/upstream/metadata cronutils-1.10/debian/upstream/metadata --- cronutils-1.9/debian/upstream/metadata 1970-01-01 00:00:00.000000000 +0000 +++ cronutils-1.10/debian/upstream/metadata 2023-08-18 03:20:10.000000000 +0000 @@ -0,0 +1,3 @@ +--- +Bug-Database: https://github.com/google/cronutils/issues +Bug-Submit: https://github.com/google/cronutils/issues/new diff -Nru cronutils-1.9/.github/workflows/ci.yml cronutils-1.10/.github/workflows/ci.yml --- cronutils-1.9/.github/workflows/ci.yml 1970-01-01 00:00:00.000000000 +0000 +++ cronutils-1.10/.github/workflows/ci.yml 2021-11-02 06:20:20.000000000 +0000 @@ -0,0 +1,11 @@ +name: CI +on: + push: + pull_request: +jobs: + test: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: test + run: make test diff -Nru cronutils-1.9/.github/workflows/codeql-analysis.yml cronutils-1.10/.github/workflows/codeql-analysis.yml --- cronutils-1.9/.github/workflows/codeql-analysis.yml 1970-01-01 00:00:00.000000000 +0000 +++ cronutils-1.10/.github/workflows/codeql-analysis.yml 2021-11-02 06:20:20.000000000 +0000 @@ -0,0 +1,67 @@ +# For most projects, this workflow file will not need changing; you simply need +# to commit it to your repository. +# +# You may wish to alter this file to override the set of languages analyzed, +# or to provide custom queries or build logic. +# +# ******** NOTE ******** +# We have attempted to detect the languages in your repository. Please check +# the `language` matrix defined below to confirm you have the correct set of +# supported CodeQL languages. +# +name: "CodeQL" + +on: + push: + branches: [ master ] + pull_request: + # The branches below must be a subset of the branches above + branches: [ master ] + schedule: + - cron: '38 5 * * 3' + +jobs: + analyze: + name: Analyze + runs-on: ubuntu-latest + + strategy: + fail-fast: false + matrix: + language: [ 'cpp' ] + # CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python' ] + # Learn more: + # https://docs.github.com/en/free-pro-team@latest/github/finding-security-vulnerabilities-and-errors-in-your-code/configuring-code-scanning#changing-the-languages-that-are-analyzed + + steps: + - name: Checkout repository + uses: actions/checkout@v2 + + # Initializes the CodeQL tools for scanning. + - name: Initialize CodeQL + uses: github/codeql-action/init@v1 + with: + languages: ${{ matrix.language }} + # If you wish to specify custom queries, you can do so here or in a config file. + # By default, queries listed here will override any specified in a config file. + # Prefix the list here with "+" to use these queries and those in the config file. + # queries: ./path/to/local/query, your-org/your-repo/queries@main + + # Autobuild attempts to build any compiled languages (C/C++, C#, or Java). + # If this step fails, then you should remove it and run the build manually (see below) + - name: Autobuild + uses: github/codeql-action/autobuild@v1 + + # ℹī¸ Command-line programs to run using the OS shell. + # 📚 https://git.io/JvXDl + + # ✏ī¸ If the Autobuild fails above, remove it and uncomment the following three lines + # and modify them (or add more) to build your code if your project + # uses a compiled language + + #- run: | + # make bootstrap + # make release + + - name: Perform CodeQL Analysis + uses: github/codeql-action/analyze@v1 diff -Nru cronutils-1.9/README.md cronutils-1.10/README.md --- cronutils-1.9/README.md 2015-12-30 04:21:21.000000000 +0000 +++ cronutils-1.10/README.md 2021-11-02 06:20:20.000000000 +0000 @@ -1,7 +1,7 @@ cronutils - utilities to assist running batch processing jobs ============================================================= -[![Build Status](https://travis-ci.org/google/cronutils.svg?branch=master)](https://travis-ci.org/google/cronutils) +![ci](https://github.com/google/cronutils/workflows/CI/badge.svg) cronutils is a set of tools to assist the reliable running of periodic and batch jobs. diff -Nru cronutils-1.9/runalarm.c cronutils-1.10/runalarm.c --- cronutils-1.9/runalarm.c 2015-12-30 04:21:21.000000000 +0000 +++ cronutils-1.10/runalarm.c 2021-11-02 06:20:20.000000000 +0000 @@ -14,6 +14,8 @@ limitations under the License. */ +#define _GNU_SOURCE /* basename */ + #include #include #include @@ -109,7 +111,7 @@ status = run_subprocess(command, command_args, &set_timeout_alarm); alarm(0); /* shutdown the alarm */ if (alarm_triggered) { - syslog(LOG_INFO, "command '%s' timed out after %d seconds", command, + syslog(LOG_INFO, "command '%s' timed out after %d seconds", basename(command), timeout); status = 128 + SIGALRM; } diff -Nru cronutils-1.9/runlock.1 cronutils-1.10/runlock.1 --- cronutils-1.9/runlock.1 2015-12-30 04:21:21.000000000 +0000 +++ cronutils-1.10/runlock.1 2021-11-02 06:20:20.000000000 +0000 @@ -16,7 +16,7 @@ \fBrunlock\fR tries to hold an exclusive lock while it executes a command. Subsequent execution of \fBrunlock\fR with the same lock, while that lock is held, will cause the new instance of \fBrunlock\fR -to terminate with a faliure exit code. Otherwise, the exit code of the +to terminate with a failure exit code. Otherwise, the exit code of the subprocess is returned. .SH USAGE diff -Nru cronutils-1.9/runlock.c cronutils-1.10/runlock.c --- cronutils-1.9/runlock.c 2015-12-30 04:21:21.000000000 +0000 +++ cronutils-1.10/runlock.c 2021-11-02 06:20:20.000000000 +0000 @@ -14,8 +14,7 @@ limitations under the License. */ -/* For asprintf */ -#define _GNU_SOURCE +#define _GNU_SOURCE /* asprintf, basename */ #include #include @@ -119,7 +118,7 @@ setlogmask(LOG_UPTO(LOG_INFO)); if (lock_filename == NULL) { - if (asprintf(&lock_filename, "%s/%s.pid", make_tempdir(), command) == -1) { + if (asprintf(&lock_filename, "%s/%s.pid", make_tempdir(), basename(command)) == -1) { perror("asprintf"); exit(EX_OSERR); } diff -Nru cronutils-1.9/runstat.c cronutils-1.10/runstat.c --- cronutils-1.9/runstat.c 2015-12-30 04:21:21.000000000 +0000 +++ cronutils-1.10/runstat.c 2021-11-02 06:20:20.000000000 +0000 @@ -14,7 +14,7 @@ limitations under the License. */ -#define _GNU_SOURCE /* dprintf(), asprintf */ +#define _GNU_SOURCE /* dprintf, asprintf, basename */ #include #include @@ -94,6 +94,7 @@ char * temp_filename = NULL; char * command; char ** command_args; + char * command_base; struct timeval start_wall_time, end_wall_time; struct timespec start_run_time, end_run_time; long int elapsed_sec, elapsed_nsec; @@ -155,9 +156,9 @@ clock_gettime(CLOCK_MONOTONIC, &end_run_time); gettimeofday(&end_wall_time, NULL); - + command_base = basename(command); if (statistics_filename == NULL) { - if (asprintf(&statistics_filename, "%s/%s.stat", make_tempdir(), command) == -1) { + if (asprintf(&statistics_filename, "%s/%s.stat", make_tempdir(), command_base) == -1) { perror("asprintf"); exit(EX_OSERR); } @@ -239,7 +240,7 @@ /* CSV emitter */ for (var = var_list; var != NULL; var = var->next) { snprintf(buf, sizeof(buf), "%s,%s,%s,%s\n", - command, + basename(command), var->name, var->value, var->units ? var->units : "" @@ -303,7 +304,7 @@ } dprintf(s, "PUTVAL \"%s/runstat-%s/%s-%s\" %.0g:%s\n", hostname, - basename(command), + command_base, type, var->name, difftime(end_wall_time.tv_sec, 0), var->value); diff -Nru cronutils-1.9/subprocess.c cronutils-1.10/subprocess.c --- cronutils-1.9/subprocess.c 2015-12-30 04:21:21.000000000 +0000 +++ cronutils-1.10/subprocess.c 2021-11-02 06:20:20.000000000 +0000 @@ -129,7 +129,7 @@ alarm(0); if (pid > 0) { if (pid != childpid) { - syslog(LOG_ERR, "childpid %d not retured by waitpid! instead %d", + syslog(LOG_ERR, "childpid %d not returned by waitpid! instead %d", childpid, pid); kill_process_group(); exit(EX_OSERR); diff -Nru cronutils-1.9/.travis.yml cronutils-1.10/.travis.yml --- cronutils-1.9/.travis.yml 2015-12-30 04:21:21.000000000 +0000 +++ cronutils-1.10/.travis.yml 1970-01-01 00:00:00.000000000 +0000 @@ -1,2 +0,0 @@ -language: c -script: make test