Firstly, I have no failure.txt log to prove the Autoplaylist or CWB Hooks is the cause because each time there is an Unhandled Exception: Bad Allocation error foobar does not create the failure log.
I have an Autoplaylist set up to display the most recently added files using this query:
Query: NOT added MISSING AND "$cwb_datediff(%cwb_systemdate%,$substr(%added%,1,11))" LESS 30
Sort format: %added% - %artist% - %date% - %album% - %tracknumber%
Keep entire playlist sorted is checked.
The majority of times foobar crashes is when I am adding new files to the database whereby the New File Tagger kicks in and creates an ADDED tag with the current timestamp, then as its done processing the tags fb2k crashes. Or it will crash when I am rescanning the library (and a few times upon exiting foobar).
I came by a scenario where I kept adding the same group of tracks to my playlist/database and foobar would crash each time. I removed the Autoplaylist component and it didn't crash during the same scenario. With the New File Tagger enabled and the Autoplaylist component removed, I've been removing and adding files from the database and I cannot reproduce any crash now where it would usually crash. So the aforementioned is all I have to go by -- I know the evidence is pretty weak.
Maybe someone who actually knows what they are doing can look into that and see if there is actually a problem with the Autoplaylist component?
By the way I was using:
foobar2000 v0.9.4.3 on Windows Vista Ultimate x64
foo_autoplaylist v1.0
foo_cwb_hooks 1.2.5 [June 7 2007 ... ]