The easiest would be to select the img using expression in jsoup if you don't assign it a unique parameter:
Elements elements = doc.select("img[src$=_one_way.gif");
Element firstElement = elements.first();
Then, you can always change an elements attribute:
firstElement.attr("src", firstElement.attr("src").replaceFirst("^(.*?)(_one_way\\.gif)$", "$1") + "_one_way.gif");