Closed jyg closed 3 years ago
I can reproduce the bug on Linux (not MacOS and I didn't test on Windows yet). The problem also occurs using Ardour.
Here is an abstraction to insert before [textfile] / [text define] inlet in order to prevent crash.
#239-workaround.pd.zip
It seems that this call of error() generates a crash. The only way I managed to fix the problem is to remove this line. I couldn't find the exact cause of the crash so far, I tried to remove all the content of the error() function so the function doesn't do anything but it still crashes. It seems that the address of the function is not valid...
Perhaps it gets confused with this function?
It seems that this call of error() generates a crash.
Yes, and indeed soundfiler_read uses pd_error() instead of error() and doesn't crash.
Perhaps it gets confused with this function?
You mean it should be linked instead with
EXTERN void error(const char *fmt, ...) ATTRIBUTE_FORMAT_PRINTF(1, 2);
as defined in m_pd.h ?
You mean it should be linked instead with
EXTERN void error(const char *fmt, ...) ATTRIBUTE_FORMAT_PRINTF(1, 2);
as defined in m_pd.h ?
Yes, this is my assumption. But for an obscure reason, it links with another function named error()...
It shoud be related to Juce framework ?
Another potential crasher : g_clone.c that contains an error()
call.
Put [clone print 4]
in a patch and it generates the error clone: can't clone 'print' because it's not an abstraction
. This crashes the plugin.
It shoud be related to Juce framework ?
I don't think but I'm not sure. I sent a mail on the pd-dev list to get some help from libpd and linux gurus
Another potential crasher : g_clone.c that contains an error() call.
In fact, all the uses of the error()
function cause a crash. And the function is used many times... :(
I did a dirty hack but can you confirm that the bug is fixed with these binaries?
yes it works ! Thanks
@jyg I found a good fix. Can you test the Linux artifacts of this commit? Thank you!
I tested camomile.so and camomileFx.so . It works perfectly, doesn't crash anymore. Thanks !
when sending a message [read ...( to [textfile] or [text define ...], plugin crashes if the specified file doesn't exist.
tested on linux 18.04-5 LTS with latest reaper 64 and camomille vst3 v1.0.8 beta (using PdStalFx plugin to load the patch)
Open the attached patch. test_textfile.pd.zip
if you click on the second row of bngs, you load the existing test_textfile.pd into [textfile] and [text define] objects if you click on the first row, you are trying to load an unexisting file and the plugin crashes![image](https://user-images.githubusercontent.com/1431894/107047390-0f22ef80-67c8-11eb-92fb-42f4c7bea83c.png)