Fixing leaks - more errors present