A Slovenian envoy jailed for spying in Sudan had been given a presidential pardon, Sudan's state news agency says.
Tomo Kriznar had travelled to the troubled Darfur region
Tomo Kriznar, 52, was arrested in July after arriving from Chad and charged with espionage, false reporting and entering without a visa.
Kriznar was later sentenced to two years' imprisonment.
Slovenian President Janez Drnovsek wrote to his Sudanese counterpart, Omar al-Beshir, last week to ask for a pardon for the envoy.
Mr Drnovsek told Mr Beshir: "Kriznar's only task was within the margins of the peace process.
"We ask the Sudanese authority to consider him as a friend and to let him come back as soon as possible."
In addition to his imprisonment, Kriznar was fined 500,000 Sudanese dinars ($2,400) and ordered to be deported after finishing his jail term.
Kriznar is well known in Slovenia as a human rights activist.
He travelled to Sudan's troubled Darfur region in February as the Slovenian president's envoy.
Three months ago, Slovenia held talks with two rebel movements which refused to accept a peace agreement between the main rebel faction and Khartoum.
Sudanese investigators said Kriznar was travelling around Darfur taking pictures and shooting video material of villages there.
The conflict in Darfur, a vast region in western Sudan, started in 2003 when members of ethnic African tribes rebelled against the Arab-led government in Khartoum.
Sudan's government is accused of sending militias to attack Darfur civilians.
It is estimated that more than 200,000 people have died and more than two million have fled their homes in the conflict.
A peace plan agreed to in May is still being opposed by some rebel groups.