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

Bug#950950: marked as done (hamlib: Please include patch to fix unaligned access in dummy/dummy.c)



Your message dated Sat, 08 Feb 2020 19:44:05 +0000
with message-id <E1j0W1N-0000Js-0I@fasolo.debian.org>
and subject line Bug#950950: fixed in hamlib 3.3-9
has caused the Debian Bug report #950950,
regarding hamlib: Please include patch to fix unaligned access in dummy/dummy.c
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 owner@bugs.debian.org
immediately.)


-- 
950950: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=950950
Debian Bug Tracking System
Contact owner@bugs.debian.org with problems
--- Begin Message ---
Source: hamlib
Version: 3.3-8
Severity: normal
Tags: patch
User: debian-sparc@lists.debian.org
Usertags: sparc64

Hi!

The attached patch fixes an unaligned access in dummy_get_level() which
resulted in the testsuite crashing on sparc64 [1].

I have opened a pull request upstream as well to address the issue [2],
so carrying the patch should hopefully not be necessary in the future.

Thanks,
Adrian

> [1] https://buildd.debian.org/status/fetch.php?pkg=hamlib&arch=sparc64&ver=3.3-8&stamp=1580780480&raw=0

--
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer - glaubitz@debian.org
`. `'   Freie Universitaet Berlin - glaubitz@physik.fu-berlin.de
  `-    GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913
dummy/dummy.c: Fix unaligned access in dummy_get_level()

This fixes an unaligned access in dummy/dummy.c in the function
dummy_get_level() which resulted in crashes (Bus Error) on systems
with stricter alignment requirements such as SPARC.

On x86_64 (and any other architecture with less strict alignment
requirements), the compiler automatically optimizes the memcpy()
out if necessary such that there are no performance issues.

--- hamlib-3.3.orig/dummy/dummy.c
+++ hamlib-3.3/dummy/dummy.c
@@ -834,7 +834,7 @@ static int dummy_get_level(RIG *rig, vfo
     }
   }
 
-  *val = curr->levels[idx];
+  memcpy (val, &curr->levels[idx], sizeof(value_t));
   rig_debug(RIG_DEBUG_VERBOSE,"%s called: %s\n",__FUNCTION__,
 				  rig_strlevel(level));
 

--- End Message ---
--- Begin Message ---
Source: hamlib
Source-Version: 3.3-9

We believe that the bug you reported is fixed in the latest version of
hamlib, 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 950950@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
tony mancill <tmancill@debian.org> (supplier of updated hamlib 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 ftpmaster@ftp-master.debian.org)


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512

Format: 1.8
Date: Sat, 08 Feb 2020 10:24:46 -0800
Source: hamlib
Architecture: source
Version: 3.3-9
Distribution: unstable
Urgency: medium
Maintainer: Debian Hamradio Maintainers <debian-hams@lists.debian.org>
Changed-By: tony mancill <tmancill@debian.org>
Closes: 950950
Changes:
 hamlib (3.3-9) unstable; urgency=medium
 .
   * Team upload.
   * Add fix_unaligned_access patch (Closes: #950950)
     Thank you to John Paul Adrian Glaubitz for the report and patch.
   * Bump Standards-Version to 4.5.0
   * Set "Rules-Requires-Root: no" in debian/control
   * Specify debhelper compat 12 via debhelper-compat dependency
Checksums-Sha1:
 b0e99d8e8c726821c5dce2d216a7b6a54fe87a32 2929 hamlib_3.3-9.dsc
 15181418828c0e4b4e1cd50e2e41ecdc81f0f628 24124 hamlib_3.3-9.debian.tar.xz
 06166048cbf62715c0d73b70394b660e692310cf 14676 hamlib_3.3-9_amd64.buildinfo
Checksums-Sha256:
 817b9ff0d025744031434062f467f26fb3bb5179798dba879b9f6d9692720a38 2929 hamlib_3.3-9.dsc
 e772e663a626cd4a4f8e363bcb107a280ab7df84888ce72d8a7b3dd7b7e0398e 24124 hamlib_3.3-9.debian.tar.xz
 f3b037e41c3b2818eb25708456b786ad9528f822436b1e020484b5eb8287d6e1 14676 hamlib_3.3-9_amd64.buildinfo
Files:
 c3268a63fa4ec7a0b2404091d1484fd3 2929 hamradio optional hamlib_3.3-9.dsc
 d9cf272a17157f537697b222855cae72 24124 hamradio optional hamlib_3.3-9.debian.tar.xz
 9a26fd180b3d145e2acef3182552e4b8 14676 hamradio optional hamlib_3.3-9_amd64.buildinfo

-----BEGIN PGP SIGNATURE-----

iQJIBAEBCgAyFiEE5Qr9Va3SequXFjqLIdIFiZdLPpYFAl4+/0wUHHRtYW5jaWxs
QGRlYmlhbi5vcmcACgkQIdIFiZdLPpbZlw//URWmbcM4uupOigPf/7OXA5BLliZL
6l6niL/y70gT282JjnrVLV40UYfrTtiCmQDHRjhVGlLKFYF7Hp2kwt9vDmPfecMb
FonmVUwt+zubjyf/u18K5nRWukXBW0Unbk9u0KVLKFNCq8v6m7fMGSILmc/OvD9v
Pf2qPI7P5pE3PJGZ907MSh9VMCXcaJ59uTHUm0h1+SjcDIbL0TVc2ZsMv6Q8GGbo
DDinJ48hnxde5vxIjveekpeHijaeHD3ULL9aVd4pt0ffrqvwd5eayifutmErgYxh
mufdbg1O+IHINoPBBvXS9MuRnEUHjHvVjJu5w9QzaKqbI47K6Q21HCHuZeNf5CRQ
ciKoaJMA3gbLsks3HyfB9ObidLgdOGyYeNxUpPHHD3GDtnuLV8mR4h2ipGZH5Z7b
0OkSrKhxL5Yfi7EFgvTUjJCd2n0US3K6R5vVMa/iHKkLY/eWzYUaLH3seUcwGlqq
aOQ6QnBX5ZYlkA1zYDfyP/7NFLCJvl0LJbvqiAIN+1d7J40mN17+YUz0FCapmVfY
T66SDp+oY3uHmpl1mu4azZXcHmxAMeca/eSxaKM1NsvSoMndaDnCJJYCcRu9yOxU
OW+7mOZtgHJjwz8oAk6ZGCgSLMR+ZzJ7zDAa/mbHWsi05PaSzhhFVgUhVsRDmJNr
tjb+gzK0+hNmQM8=
=WtTn
-----END PGP SIGNATURE-----

--- End Message ---

Reply to: