Fixed bug with storing filename when throwing exception.
New function acu_swap. Optimized acu_submit_to in thread safe mode.