Fixing some bugs with the pooling system.