Are you sure the problem is in your Java program? Try writing a short shell script that captures the return value and prints it (so there's no Java involved at all). Can you get values greater than 128?
"I'm not back." - Bill Harding, Twister
Anil kumar P
Joined: Jan 16, 2008
The shell script is returning value as 255 only. But the java programme is returning as -1.
If the return value is less than 128, then java is also returning correctly as 128.