Package: aplus-fsf
Version: 4.22.1-8
Severity: important
Tags: patch
User: ubuntu-de...@lists.ubuntu.com
Usertags: origin-ubuntu yakkety ubuntu-patch

Hi Neil,

The Ubuntu autobuilders have detected a problem with your package on 64-bit
architectures.  The C code is using functions that are only declared in C++
headers, and thus failing to include prototypes for them before calling
them, which which means there's an implicit declaration.  Implicit
declarations are treated as returning an int, but two of these functions
return a pointer.  This means that on 64-bit architectures the return value
will be truncated, typically resulting in a segfault.

I have only marked this bug as 'important' because I don't know how
important these code paths are in aplus-fsf.  Maybe the bug should be
treated as 'serious' or 'grave'.  Regardless, such segfault bugs are treated
as build failures in Ubuntu, so I've applied the attached patch in Ubuntu to
fix the failure.

Thanks for considering the patch.
-- 
Steve Langasek                   Give me a lever long enough and a Free OS
Debian Developer                   to set it on, and I can move the world.
Ubuntu Developer                                    http://www.debian.org/
slanga...@ubuntu.com                                     vor...@debian.org
only in patch2:
unchanged:
--- aplus-fsf-4.22.1.orig/src/esf/fmt.c
+++ aplus-fsf-4.22.1/src/esf/fmt.c
@@ -24,6 +24,9 @@
 #include <a/x.h>
 #include <a/fir.h>
 
+/* shadowed declaration for C++ function */
+void *ga(long t,long r,long n,long *d);
+
 #define DATAINC 100
 
 /* Token types */
only in patch2:
unchanged:
--- aplus-fsf-4.22.1.orig/src/esf/primpro.c
+++ aplus-fsf-4.22.1/src/esf/primpro.c
@@ -13,6 +13,9 @@
 #include <a/k.h>
 #include <a/x.h>
 
+/* shadowed declaration for C++ function */
+void *gi(long i);
+
 #define NUM_TYPES 4
 #define NUM_BUCKETS 9
 #define NUM_CPU_BUCKETS 2

Reply via email to