'check if file exists before download - Qt

I have a URL of a file and I want to download it from the internet. Before downloading, I want to make sure that the file I am going to download actually exists i.e, the URL is correct or the file has not been deleted by the owner. How am I supposed to do so in Qt?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source