Improved flare-stats output and fixed invalid digit problem