Submitted by gpersoon
If you call the function withdrawFees when TVL is not enough for the fee, then the code  would revert. In this case the fees cannot be withdrawn. Although it is unlikely that the TVL would be wrong, it is probably better to be able to withdraw the remaining fees.
TracerPerpetualSwaps.sol L508
Recommend adding something like tempFees = min (fees, tvl);, and changing fees=0 to fees -= tempFees;
raymogg (Tracer) confirmed
