Your message dated Mon, 01 Oct 2018 15:21:32 +0000
with message-id <[email protected]>
and subject line Bug#897747: fixed in faketime 0.9.7-2.1
has caused the Debian Bug report #897747,
regarding faketime: FTBFS with GCC 8 - error: 'strncpy' specified bound 256
equals destination size
to be marked as done.
This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.
(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)
--
897747: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=897747
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Source: faketime
Version: 0.9.7-1
Severity: important
User: [email protected]
Usertag: ftbfs-gcc-8
Hi,
I recently performed an (unofficial) archive rebuild with GCC 8 on
mips64el. The main purpose of the rebuild was to discover mips toolchain
regressions, however I noticed this error in the logs which might be
interesting to you:
> faketime.c: In function 'main':
> faketime.c:289:45: error: '%s' directive output may be truncated writing up
> to 4095 bytes into a region of size between 0 and 4095
> [-Werror=format-truncation=]
> snprintf(shared_objs, PATH_BUFSIZE, "%s %s", sem_name, shm_name);
> ^~ ~~~~~~~~
> faketime.c:289:5: note: 'snprintf' output between 2 and 8192 bytes into a
> destination of size 4096
> snprintf(shared_objs, PATH_BUFSIZE, "%s %s", sem_name, shm_name);
> ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> In file included from libfaketime.c:49:
> libfaketime.c: In function 'fake_clock_gettime':
> libfaketime.c:1986:24: error: cast between incompatible function types from
> 'int (*)(pthread_mutex_t *)' {aka 'int (*)(union <anonymous> *)'} to 'void
> (*)(void *)' [-Werror=cast-function-type]
> pthread_cleanup_push((void (*)(void *))pthread_mutex_unlock, (void
> *)&time_mutex);
> ^
> cc1: all warnings being treated as errors
> Makefile:98: recipe for target 'faketime' failed
> make[2]: *** [faketime] Error 1
> make[2]: *** Waiting for unfinished jobs....
> libfaketime.c: In function 'fake_clock_gettime.part.4':
> libfaketime.c:2081:7: error: 'strncpy' specified bound 256 equals destination
> size [-Werror=stringop-truncation]
> strncpy(user_faked_time, tmp_env, BUFFERLEN);
> ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> libfaketime.c:2081:7: error: 'strncpy' specified bound 256 equals destination
> size [-Werror=stringop-truncation]
> strncpy(user_faked_time, tmp_env, BUFFERLEN);
> ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> libfaketime.c: In function 'ftpl_init':
> libfaketime.c:1831:12: error: 'strncpy' specified bound 1024 equals
> destination size [-Werror=stringop-truncation]
> (void) strncpy(ft_spawn_target, getenv("FAKETIME_SPAWN_TARGET"), 1024);
> ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> libfaketime.c:1892:5: error: 'strncpy' specified bound 8192 equals
> destination size [-Werror=stringop-truncation]
> strncpy(user_faked_time_fmt, tmp_env, BUFSIZ);
> ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> libfaketime.c: In function 'ftpl_init':
> libfaketime.c:1831:12: error: 'strncpy' specified bound 1024 equals
> destination size [-Werror=stringop-truncation]
> (void) strncpy(ft_spawn_target, getenv("FAKETIME_SPAWN_TARGET"), 1024);
> ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> libfaketime.c:1892:5: error: 'strncpy' specified bound 8192 equals
> destination size [-Werror=stringop-truncation]
> strncpy(user_faked_time_fmt, tmp_env, BUFSIZ);
> ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> cc1: all warnings being treated as errors
> Makefile:92: recipe for target 'libfaketime.o' failed
> make[2]: *** [libfaketime.o] Error 1
> cc1: all warnings being treated as errors
> Makefile:92: recipe for target 'libfaketimeMT.o' failed
> make[2]: *** [libfaketimeMT.o] Error 1
> make[2]: Leaving directory '/<<PKGBUILDDIR>>/src'
> Makefile:7: recipe for target 'all' failed
> make[1]: *** [all] Error 2
> make[1]: Leaving directory '/<<PKGBUILDDIR>>'
> dh_auto_build: make -j3 "INSTALL=install --strip-program=true" returned exit
> code 2
> debian/rules:22: recipe for target 'build-arch' failed
> make: *** [build-arch] Error 2
> dpkg-buildpackage: error: debian/rules build-arch subprocess returned exit
> status 2
As you probably know, you need to be careful using strncpy.
Instead of:
char out[SIZE];
strncpy(out, in, SIZE);
You need to do:
char out[SIZE]
strncpy(out, in, SIZE - 1);
out[SIZE - 1] = '\0';
See strcpy(3)
James
signature.asc
Description: OpenPGP digital signature
--- End Message ---
--- Begin Message ---
Source: faketime
Source-Version: 0.9.7-2.1
We believe that the bug you reported is fixed in the latest version of
faketime, which is due to be installed in the Debian FTP archive.
A summary of the changes between this version and the previous one is
attached.
Thank you for reporting the bug, which will now be closed. If you
have further comments please address them to [email protected],
and the maintainer will reopen the bug report if appropriate.
Debian distribution maintenance software
pp.
Tobias Frost <[email protected]> (supplier of updated faketime package)
(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing [email protected])
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256
Format: 1.8
Date: Sat, 29 Sep 2018 16:35:04 +0200
Source: faketime
Binary: faketime libfaketime
Architecture: source
Version: 0.9.7-2.1
Distribution: unstable
Urgency: medium
Maintainer: Daniel Kahn Gillmor <[email protected]>
Changed-By: Tobias Frost <[email protected]>
Description:
faketime - Report faked system time to programs (command-line tool)
libfaketime - Report faked system time to programs (preload library)
Closes: 897747
Changes:
faketime (0.9.7-2.1) unstable; urgency=medium
.
* Non-maintainer upload.
* Cherry-Pick fixes for the FTBFS with gcc-8 from upstream git
repository. (Closes: #897747)
Checksums-Sha1:
ec2615155ce66d554e691d9d4b875463792d45c4 1930 faketime_0.9.7-2.1.dsc
c4ac34ae07629d9696107745749c09e3ffc2bf0b 7136 faketime_0.9.7-2.1.debian.tar.xz
04c7aac35e56b5ab56427cd155923d165284c256 5526
faketime_0.9.7-2.1_source.buildinfo
Checksums-Sha256:
f91b3daa8cb832629c2537fd639f9f1083b04b16b6e00b8f533e531cae5abe12 1930
faketime_0.9.7-2.1.dsc
50001346518468173181830b67d1bfdf9f627d950f7b583e03182e9f7e23164e 7136
faketime_0.9.7-2.1.debian.tar.xz
a11da736a380a4c7e7a7031db15f282a1b7b86157e86260fd6db8274b0fdac3f 5526
faketime_0.9.7-2.1_source.buildinfo
Files:
1cb3e029752a31b2faebf237066b2e0b 1930 utils optional faketime_0.9.7-2.1.dsc
5f81050a4b979c4b9791ce0c52c00227 7136 utils optional
faketime_0.9.7-2.1.debian.tar.xz
db82e44e38f6e6a17705dc735d40b478 5526 utils optional
faketime_0.9.7-2.1_source.buildinfo
-----BEGIN PGP SIGNATURE-----
iQIzBAEBCAAdFiEE/d0M/zhkJ3YwohhskWT6HRe9XTYFAluvj5kACgkQkWT6HRe9
XTb9mg/9H+p64411iVjM551UCq6FV7hGyIkeedrVCegZ9RqlAmS6tq1sJopKaIfS
+7cCIWo1lVbnaFEwRIrMc4ysS1yyTEetZlwNrLE0krlb4wg6fBHYrUgTw12ABRF0
WT4mE3s7Tqh6wH1uY1r9jjaAY3wXRd8aiiaF5rvH+QqVwIJVYGJkNaPinV9n90uI
hprB1k8Ek2vRlWZFs3+MXw0TTvrN7kxGBVjuN87OmgIwETMaQFdI614iPqsjfepX
GgUewrm7Nxu000R9iZQzH3fcoNvVyCDiwYu/CMG5a7/Qxxbv8F9f1avbnJv2GagM
vcZxo408P/+BmBCv58XlQTVExvZM7H94oCW3+gvA4gm1ouvVWQ0weMlnGT/NzVsb
GKQCz8yRFuKHNjykUb5lSzWRWOocwXXZeonDtqLsbzLNF2W4ufsk/rcEEJUYZHlj
HIvuwdfbvfm1QJipzIZ4Q1Bf8kdBCEbAC9zo75DlehVxUmNanmKy+YeFv+nsAcCI
/UvDAPF4HHCLdW2tnrohL/q9HQYl9Qj5I9i4oNCChI3hKTi4FPjVlcJWQOZrnnB0
NWE6A8hotjZSASlxLWz8sZtuQ4GNa1S5BXPjwUDS94yhed4F/bPHbHg3K/auxC+G
VuXRGnRGThFQpl3DbmZc5msbd186GXb8O/8MI4Ckdl8l0tfKKNE=
=nhXm
-----END PGP SIGNATURE-----
--- End Message ---