Code: Select all
try {
source_img = new Image(get_url());
} catch (Exception &e) {
throw; //handled in a different part of the program
}
I was looking at http://www.imagemagick.org/Magick++/Exception.html and noticed that there is a class of "warning" exceptions, but none of them seem to cover this case. Is there any way I can detect when the url was a redirect?