Hi Ajitesh,

I have already posted my solution in another thread (not sure that it is
right one) but I will copy it below:

 

My solution to get rid of these line feed chars was as following (added
lines in bold):

 

ConnectionClient.java:

 

/*  Read data from the standard input and send it to the remote socket
*/

            while (true) {

                byte[] inData = new byte[100];

 

                for(int i = 0; i < inData.length; i++)

                    inData[i]= ' ';

 

                System.in.read(inData);

 

 

Regards,

Moria.

 

 

________________________________

From: [email protected]
[mailto:[email protected]] On Behalf Of
ajitesh gupta
Sent: Thursday, November 05, 2009 9:11 AM
To: [email protected]
Subject: [java programming] concurrency Homeowrk byte stream junk

 

Hi

 

          while printing the read byte stream, i am getting some junk
characters (attached) along with correct one. how can i hide those?

 

thanks

ajitesh




--~--~---------~--~----~------------~-------~--~----~
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/javaprogrammingwithpassion?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to