Hard crash from fluid.bufcompose~

I’ve managed to create a repeatable hard crash with fluid.bufcompose~.

Granted, this is probably a silly message to send fluid.bufcompose~, but at minimum, it shouldn’t crash (ever):

deststartframe 99999999999, bang


----------begin_max5_patcher----------
416.3ocqT1jaCBCDEdMbJr7ZRjwgzlzU8dTUE4.CoNBrQ1l1TE0b1q8XH8OZ
TqTXAnY3YOy7wybLMgtUe.rTxcjGHIIGSSRvTgDICwIzVwgxFgEkQUvK5s6o
YwW4fCNL8195ZvbhLa1rxFceEImwXipT8s5dWC3vsfOjUVgqzuay3iJixbu1
AwdhV2nENZlu.B0NJ4wAccBW4SR0tMFnzEkxKJlyxHKJVFdjyYgGb9b14E4a
CoZrKxC4dKMMbK6pM6Zk0u+arPiuujZU.C+YJjeUn.Gm6auAovsEWeJzBVqX
G7CLTAVm0ILtZinEHq+3Jif88jbHeBNv+c+vEG93ztFumud4kGc90y.T2zKq
l6sAk51NsENQt2p6MkvjVh6CfRpDXv34kogyhofC6WgSjxext7GnU9R7fxhU
+iyKnBZiT88ecfUIj+qLLBigl77WXxGU5SD4KpXQU+nzhttmAicPNVF+Gp8Z
SHbUFFJUwPzfQMvyxQ8LLiv3AhySidC1ZzC2TPiKUWAFUubXr81CeIQSfxar
sch3rfdkz2ReGPzXJcH
-----------end_max5_patcher-----------

Here are two crash reports.

Archive.zip (74.4 KB)

edit:
this was me testing to see what happens if when you try to write to a point in the buffer that doesn’t exist.

1 Like

this is a nice catch, since it is not about size (try the same thing with 999999 and it does not crash even if it is outside the boundaries) but probably about casting 99999999999 - or maybe it is just too big: it is a touch more than 26 days of audio at CD quality :wink:

Well, sometimes you just need to fluid.bufcompose~ Zappa’s back catalog.

1 Like

Ok, I’ve got to the bottom of what caused your particular crash (carelessness about different integer types in the BufCompose code.)

However fixing that means you can now make the computer desparately unhappy by running out of application memory (on Mac – I don’t yet know how Windows will respond to this). I think 99999999999 samples at double precision = 745 GB

That’s much harder to do anything defensive against, but at least the OS tells you what’s wrong.

2 Likes