Modified main to remove Windows-specific file length operation