Enabling Disallow Infected File Download prevents malicious files from being downloaded by users within Sharepoint Online (or OneDrive or Teams) when the file is determined to be a virus.
All actions, except delete, are blocked for detected files. Detected malicious files cannot be opened, moved, copied, downloaded or shared. A visual cue will appear indicating that a file has been identified as malicious.
Complete details and images from Microsoft are in Safe Attachments for SharePoint, OneDrive, Teams (Actions).