aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorIOhannes m zmölnig <zmoelnig@users.sourceforge.net>2015-08-28 17:57:59 +0000
committerIOhannes m zmölnig <zmoelnig@users.sourceforge.net>2015-08-28 17:57:59 +0000
commitba559cdf2df1db5081c258707820bf80409dfdf1 (patch)
tree27299800ebe46b62a00d7704676855b658cf22ae /src
parent739a8290a8b05645a2d055aed8e5eb76ba2e24e6 (diff)
fix NULL-selectors
When handling 'float' messages with the list-method, the selector is set to NULL in the incoming message. however, passing that message on, inevitably leads to a crash :-( Closes https://sourceforge.net/p/pure-data/bugs/1194/ svn path=/trunk/externals/zexy/; revision=17538
Diffstat (limited to 'src')
-rw-r--r--src/relay.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/relay.c b/src/relay.c
index e1ea476..246e1f2 100644
--- a/src/relay.c
+++ b/src/relay.c
@@ -82,6 +82,9 @@ static void relay_list(t_relay *x, t_symbol *sel, int argc, t_atom *argv)
f = atom_getfloat(argv);
for (nelement = x->x_nelement, e = x->x_vec; nelement--; e++) {
if (e->e_w.w_float == f) {
+ if (!sel) {
+ sel=(argc==1)?gensym("float"):gensym("list");
+ }
outlet_anything(e->e_outlet, sel, argc, argv);
return;
}