QuoteIs this behaviour a CB bug?
The effect you see probably comes from the DevPak plugin.
There are 4 occasions where tempfiles are created:
1. Makefile creation: there
is a bug in the compiler plugin during Makefile creation, the tempfile is never deleted, but then Makefile creation is not enabled anyway, so it does not matter for now.
2. DevPak plugin: tempfiles are only deleted if decompression of a package
failed, this is a bug (and the likely cause)
3. Code completion: works properly (but is not exception safe)
4. Application startup: works properly (but is not exception safe)
Occasions 3 and 4
may leave behind a temp file if the application crashes in between creation and deletion. There is not much one can do, unluckily (a smart tempfile object could work around this, but the likelihood of failure is pretty close to zero, so the effort is not in relation to the benefit).
Occasion 2, on the other hand, will
regularly leave tempfiles.
The DevPak plugin has a couple of issues anyway. Tiwag has already identified a few such things. After the great job he did to Find and Replace, maybe we can convince him to give DevPak an overhaul, too ;)