Fixed table memory leak