Skip to content

Commit 68c2cd3

Browse files
committed
an empty o.message will correctly output an empty bundle if triggered by a list
1 parent f1c75ac commit 68c2cd3

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

o.message/o.message.c

+7-2
Original file line numberDiff line numberDiff line change
@@ -642,7 +642,7 @@ void omessage_list(t_omessage *x, t_symbol *list_sym, short argc, t_atom *argv)
642642
memcpy(copy, ptr, len);
643643
critical_exit(x->lock);
644644
omax_util_outletOSC(x->outlet, len, copy);
645-
}else{
645+
} else {
646646
if(!x->bndl_u){
647647
if(x->bndl_s){
648648
critical_enter(x->lock);
@@ -651,7 +651,12 @@ void omessage_list(t_omessage *x, t_symbol *list_sym, short argc, t_atom *argv)
651651
}else if(x->text){
652652
// pretty sure this can't happen...
653653
post("%d\n", __LINE__);
654-
}else{
654+
} else {
655+
char buf[OSC_HEADER_SIZE];
656+
memset(buf, '\0', OSC_HEADER_SIZE);
657+
osc_bundle_s_setBundleID(buf);
658+
omax_util_outletOSC(x->outlet, OSC_HEADER_SIZE, buf);
659+
jbox_redraw((t_jbox *)x);
655660
return;
656661
}
657662
}

0 commit comments

Comments
 (0)