Fixing global leak

booooooo