fix df bug: free double count