So having achieved nothing, Mehmed retreated. But in 1462 during the war with the Hungarians Tepes was caught and extradited traitors enemies. Hungarian King Matthias Hunyadi ordered to sign a prisoner in Visegrad Castle, where he spent in close confinement for fourteen years. They say that he is not leaving their cruel habits: catch mice or birds, and tortured them - some impaled, cut off the head of another, and let the birds into the wild, they plucked all the feathers. In 1476 the Impaler agreed to Catholicism, was released and again briefly reigned in Wallachia. At the end of the same year he died in a battle with the Turks. They killed him, according to tradition, by his own soldiers.