Add missing options in brevity help
Avoid scanf buffer overflow
Add pipe mode feature(-D/--pipe-mode)
Use fseek instead of rewind, and check the availability of fseek