Vietnam has freed a blogger who was recently detained over a plan to distribute anti-China T-shirts, he said on Sunday, as Communist Party chief Nong Duc Manh prepared to leave on a visit to Australia and New Zealand.

The reason Hanoi police gave Bui Thanh Hieu when they let him go on Saturday evening was the cancellation of preventative measures, said Hieu, who spent nine nights in detention.

I don't know exactly why they freed me, he said by telephone. The release may relieve some pressure over human rights that Communist Party General Secretary Manh is sure to face during a visit to Australia and New Zealand that starts on Sunday. Analysts say the Party has a history of freeing high-profile political prisoners or detainees ahead of major visits.

Hieu said Pham Doan Trang, a journalist for the highly popular news Web site VietnamNet, who was detained a day after him, had also been freed, but there was no immediate confirmation of that.

Hieu was frequently critical of government policy on issues such as China policy and Catholic Church land disputes on his blog, Nguoi Buon Gio, or Wind Trader.

CRITICAL OF CHINA

He confirmed he had been detained in connection with a plan to print and distribute to major Vietnamese cities T-shirts opposing China's involvement in a bauxite mining scheme and claims over disputed islands in the South China Sea.

Another person who was arrested last week also in connection with the T-shirt scheme, blogger Nguyen Ngoc Nhu Quynh from the southern beach town of Nha Trang, was not released, her mother said by telephone on Sunday.

Hieu said he, Trang and Quynh had been close friends for a long time, but he would did not say if the other two were involved in the T-shirt scheme.

The arrests have underscored how sensitive Vietnam's relations with China are while highlighting the challenge Hanoi faces in keeping public opinion in check as Internet usage blossoms -- and where it draws a line on organized dissent.

The bauxite issue came into the spotlight last year when war hero Gen. Vo Nguyen Giap urged the government to reconsider it. Opponents of the plan say it will be bad for the environment and contend that China's involvement is a national security risk.

Vietnam's relationship with China is laden with baggage from centuries of conflict, and the Vietnamese Communist Party performs a delicate balancing act between the need to stay on good terms with China and a populace that is highly suspicious of the giant neighbor to the north.

Analysts say the Chinese government is not shy about putting pressure on Vietnam to keep media and bloggers on a tight leash when it comes to criticism about China.

(Reporting by John Ruwitch; Editing by Bill Tarrant)