Fix bug in multi-stock allocations