pkgsrc-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: pkgsrc/pkgtools/pkg_install/files/lib



Module Name:    pkgsrc
Committed By:   wiz
Date:           Fri May  9 12:18:00 UTC 2025

Modified Files:
        pkgsrc/pkgtools/pkg_install/files/lib: pkg_signature.c

Log Message:
pkg_install: add cast for picky compilers

lib/pkg_signature.c: In function 'pkg_sign_gpg':
lib/pkg_signature.c:637:31: error: format '%lld' expects argument of type 'long long int', but argument 3 has type '__off_t' {aka 'long int'} [-Werror=format=]
  637 |         hash_file = xasprintf(hash_template, pkgname, size);
      |                               ^~~~~~~~~~~~~           ~~~~
      |                                                       |
      |                                                       __off_t {aka long int}


To generate a diff of this commit:
cvs rdiff -u -r1.14 -r1.15 \
    pkgsrc/pkgtools/pkg_install/files/lib/pkg_signature.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: pkgsrc/pkgtools/pkg_install/files/lib/pkg_signature.c
diff -u pkgsrc/pkgtools/pkg_install/files/lib/pkg_signature.c:1.14 pkgsrc/pkgtools/pkg_install/files/lib/pkg_signature.c:1.15
--- pkgsrc/pkgtools/pkg_install/files/lib/pkg_signature.c:1.14  Tue Feb 18 11:53:49 2025
+++ pkgsrc/pkgtools/pkg_install/files/lib/pkg_signature.c       Fri May  9 12:18:00 2025
@@ -1,4 +1,4 @@
-/*     $NetBSD: pkg_signature.c,v 1.14 2025/02/18 11:53:49 wiz Exp $   */
+/*     $NetBSD: pkg_signature.c,v 1.15 2025/05/09 12:18:00 wiz Exp $   */
 
 #if HAVE_CONFIG_H
 #include "config.h"
@@ -7,7 +7,7 @@
 #if HAVE_SYS_CDEFS_H
 #include <sys/cdefs.h>
 #endif
-__RCSID("$NetBSD: pkg_signature.c,v 1.14 2025/02/18 11:53:49 wiz Exp $");
+__RCSID("$NetBSD: pkg_signature.c,v 1.15 2025/05/09 12:18:00 wiz Exp $");
 
 /*-
  * Copyright (c) 2008 Joerg Sonnenberger <joerg%NetBSD.org@localhost>.
@@ -634,7 +634,7 @@ pkg_sign_gpg(const char *name, const cha
        size = archive_entry_size(entry);
 
        pkgname = extract_pkgname(fd);
-       hash_file = xasprintf(hash_template, pkgname, size);
+       hash_file = xasprintf(hash_template, pkgname, (long long)size);
        free(pkgname);
 
        for (i = 0; i < size; i += block_len) {



Home | Main Index | Thread Index | Old Index