Bug#750168: puredata: Conflicting declarations of function glist_scalar to cause undefined behaviour

2014-06-02 Thread Michael Tautschnig
Package: puredata
Version: 0.45.4-1
Usertags: goto-cc

During a rebuild of all Debian packages in a clean sid chroot (using cowbuilder
and pbuilder) the build failed with the following error. Please note that we
use our research compiler tool-chain (using tools from the cbmc package), which
permits extended reporting on type inconsistencies at link time.

[...]
libtool: link: gcc -DPD -DINSTALL_PREFIX=\/usr\ -DUSEAPI_ALSA -DUSEAPI_JACK 
-DJACK_XRUN -DUSEAPI_OSS -DUSEAPI_PORTAUDIO -O3 -funroll-loops 
-fomit-frame-pointer -g -O2 -fstack-protector --param=ssp-buffer-size=4 
-Wformat -Werror=format-security -Wl,-z -Wl,relro -Wl,--as-needed -o pd 
pd-g_canvas.o pd-g_graph.o pd-g_text.o pd-g_rtext.o pd-g_array.o 
pd-g_template.o pd-g_io.o pd-g_scalar.o pd-g_traversal.o pd-g_guiconnect.o 
pd-g_readwrite.o pd-g_editor.o pd-g_all_guis.o pd-g_bang.o pd-g_hdial.o 
pd-g_hslider.o pd-g_mycanvas.o pd-g_numbox.o pd-g_toggle.o pd-g_vdial.o 
pd-g_vslider.o pd-g_vumeter.o pd-m_pd.o pd-m_class.o pd-m_obj.o pd-m_atom.o 
pd-m_memory.o pd-m_binbuf.o pd-m_conf.o pd-m_glob.o pd-m_sched.o pd-s_main.o 
pd-s_inter.o pd-s_file.o pd-s_print.o pd-s_loader.o pd-s_path.o pd-s_entry.o 
pd-s_audio.o pd-s_midi.o pd-s_utf8.o pd-d_ugen.o pd-d_ctl.o pd-d_arithmetic.o 
pd-d_osc.o pd-d_filter.o pd-d_dac.o pd-d_misc.o pd-d_math.o pd-d_fft.o 
pd-d_array.o pd-d_global.o pd-d_delay.o pd-d_resample.o pd-d_soundfile.o 
pd-x_arithmetic.o pd-x_connective.o pd-x_interface.o pd-x_midi.o pd-x_misc.o 
pd-x_time.o pd-x_acoustics.o pd-x_net.o pd-x_text.o pd-x_gui.o pd-x_list.o 
pd-x_array.o pd-x_scalar.o pd-s_audio_alsa.o pd-s_audio_alsamm.o 
pd-s_midi_alsa.o pd-d_fft_mayer.o pd-d_fftroutine.o pd-s_audio_jack.o 
pd-s_audio_oss.o pd-s_midi_oss.o pd-s_audio_pa.o pd-s_audio_paring.o 
-Wl,--export-dynamic  -lm -lasound -ljack -lportaudio -lpthread -ldl -lrt

error: conflicting function declarations glist_scalar
old definition in module g_canvas file g_canvas.c line 1527
void (struct _glist *, struct _symbol *, signed int, struct _atom *)
new definition in module g_scalar file g_scalar.c line 133
void (struct _glist *glist, struct _symbol *classname, signed long int argc, 
struct _atom *argv)
Makefile:671: recipe for target 'pd' failed
make[3]: *** [pd] Error 64
make[3]: Leaving directory 
'/srv/jenkins-slave/workspace/sid-goto-cc-puredata/puredata-0.45.4/src'
Makefile:903: recipe for target 'all-recursive' failed
make[2]: *** [all-recursive] Error 1

For any platform with sizeof(int)sizeof(long) the call to glist_scalar will
have undefined behaviour as several bytes remain undefined and will thus take an
arbitrary value.

Adjusting the declaration in g_canvas.c should fix this problem.

Best,
Michael



pgpZ7n0VlhXp2.pgp
Description: PGP signature


Bug#750168: puredata: Conflicting declarations of function glist_scalar to cause undefined behaviour

2014-06-02 Thread IOhannes m zmölnig (Debian/GNU)
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256

Control: tags -1 pending upstream
Control: forwarded -1 https://sourceforge.net/p/pure-data/bugs/1145/

thanks for the bug-report.
we have a fix at hand, which will part of the next upload (unless it
is fixed by upstream first).

fgmasdr
IOhannes
-BEGIN PGP SIGNATURE-
Version: GnuPG v1
Comment: Using GnuPG with Icedove - http://www.enigmail.net/

iQIcBAEBCAAGBQJTjE8lAAoJELZQGcR/ejb4l9sP/3pNOo2vEUpL1ug3Jlcuzyrp
P0aN16AEtl+1nZivivmAbaRe+pNmHufe/tMxz2zg1ZPvlnRDzxo0fanhGMidxDDw
WjU6nZdZ0J/KYHp6xnRJyMw8FAnY7cjscScuwi69YTME/Qz2Ki8EyrceIYU120N0
QPo6s5OHXZHnBetwF2+xj/Zy1o1/DV3xpapB69IhYFqKi37D01VPUxObZiS+/5OD
8iDh2Ix1JL7CYsoa/JsRax7ARXGvv7hphQv9nv+oB0ZBFCvxhS0dEZaBAYTzT+Q7
DwMMo0vie5B+w8Bo07sXnU/IRq2UdGkNfv4kBaCCvNaJfJGsHQ0Qzm0jYLC+RGKE
mD0uSAzS4z+jrOs1aSkD08FztrjYdEyNFI+AhyqYpfV4AFJr6SYWwDeyyazBj434
932oAOOXyHuyUmWzXlo+SXrgh9Vwh9M74dJlU3BKONZqrT9gIjIUJa+EZW8/GPU/
fjRXbhZFvVB48Gz9sgPQhuQeK2mZXyhJ8Ql6TxLYoPvVkfUfWdyotx1hwtZu92M6
jtVAcysZRKbZfeqCJmvDXP0mTGeDXtJqWlQJ5flDPY77n04f7Z0pXwedd1MNu5mI
F6y5sshx4LJsI/tEcsS+nx2HFCTHgzwmIAtQDRpa2jWq5hGFB/5ZKn+lhU9vrDFR
A4BZtEJMWKuDjhVDsog5
=BMlh
-END PGP SIGNATURE-


-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org