@rocksteady
Thanks for your reply. I am using Avast Premium and Avast Firewall. The Avast Firewall is already set to private. The issue happens when I run my application. Avast halts it while it scans it, then when it gives the OK the app doesnt recover. Killing the application and restarting it doesnt help as the application says that files are locked. Only a reboot, turning off the shields and restarting the app will fix the issue.