PDA

View Full Version : Runtime's exec() api doesn't work on Tiger




vikasu
Feb 11, 2008, 01:01 AM
Dear All,

I wrote the following code:-

Runtime rt = Runtime.getRuntime();
String strJapaneseName = m_bundle.getString("Name");
//strJapaneseName will contain Japanese characters let "によ"
String [] strCopyCmd = {"rm","/private/var/root/Desktop/"+strJapaneseName+".rtf"};
try
{
Process p = rt.exec(strCopyCmd);
} catch (IOException ex)
{ex.printStackTrace();}


Now place the によ.rtf file on Desktop, and change the locale to Japanese.
Run the code, it works fine on Leopard, but with the same scenario it doesn't work on Tiger.
Why?????

Please reply with ur suggestions.



jeremy.king
Feb 11, 2008, 11:52 AM
whats the exception?