Take a look at the following URL:
http:// www.samuel-berthelot.com / ? attachment_id=703
There is a link to the next image that reads
lumière sur la mariéat the bottom of the image. It redirects to attachment with id 704.
I have set a permanent redirection to attachment with id 1743 because they were both showing the same image that I had uploaded twice at different points in time.
So it works fine, except that I would like to change the link to open the attachment with id 1743. This way I wouldn't have a 404 warning in Google Webmaster Tools.
How can I do that with Wordpress ? I don't know how this links are generated.