improving log stats
protect against bad fd in fdopen and fp in fseek
Merge pull request #173 from pantheon-systems/dynamic-logging

Dynamic logging