Mercurial > 510Connectbot
comparison src/org/tn5250j/framework/tn5250/DataStreamProducer.java @ 219:c438c2ff0052
remove unnecessary socket run dry flagging
author | Carl Byington <carl@five-ten-sg.com> |
---|---|
date | Tue, 08 Jul 2014 10:46:40 -0700 |
parents | 3e68cb17c0b6 |
children | 7ac1a0b02f44 |
comparison
equal
deleted
inserted
replaced
218:2bdc413623b2 | 219:c438c2ff0052 |
---|---|
144 baosin.reset(); | 144 baosin.reset(); |
145 int j = -1; | 145 int j = -1; |
146 int i = 0; | 146 int i = 0; |
147 | 147 |
148 while (!done) { | 148 while (!done) { |
149 try { | |
150 if (bin.available() == 0) dsq.put(new Integer(0)); // trigger buffer.testChanged() | |
151 } | |
152 catch (Exception ex) { | |
153 Log.w(TAG, "readIncoming error " + ex.getMessage()); | |
154 } | |
155 i = bin.read(); | 149 i = bin.read(); |
156 | 150 |
157 // WVL - LDC : 16/07/2003 : TR.000345 | 151 // WVL - LDC : 16/07/2003 : TR.000345 |
158 // The inStream return -1 when end-of-stream is reached. This | 152 // The inStream return -1 when end-of-stream is reached. This |
159 // happens e.g. when the connection is closed from the AS/400. | 153 // happens e.g. when the connection is closed from the AS/400. |
222 dump(rBytes); | 216 dump(rBytes); |
223 } | 217 } |
224 | 218 |
225 if (negotiate) { | 219 if (negotiate) { |
226 // get the negotiation option | 220 // get the negotiation option |
227 try { | |
228 if (bin.available() == 0) dsq.put(new Integer(0)); // trigger buffer.testChanged() | |
229 } | |
230 catch (Exception ex) { | |
231 Log.w(TAG, "readIncoming error " + ex.getMessage()); | |
232 } | |
233 baosin.write(bin.read()); | 221 baosin.write(bin.read()); |
234 vt.negotiate(rBytes); | 222 vt.negotiate(rBytes); |
235 return null; | 223 return null; |
236 } | 224 } |
237 | 225 |