The most efficient way to free a photograph from glass is to freeze it for several hours, according to a Heloise column in the The CantonRep. Trying to pull an unfrozen photo away from the glass may ruin it.
Putting the glass and stuck photograph in a plastic freezer bag and placing it in a freezer overnight loosens the photo. If the photo does not pull away from the glass after freezing, letting it freeze for several days may do the trick. Heloise points out that professional photography shops are often able to remove a photo from glass. Another option is to see if the original photographer has the negative so a new print can be created.