Net-client: remove unneeded synchronization block

This commit is contained in:
Jakub Valtar
2018-01-22 19:50:48 +01:00
parent bb6c9a568a
commit fe465fe4de

View File

@@ -621,10 +621,9 @@ public class Client implements Runnable {
* @brief Returns the buffer as a String
*/
public String readString() {
synchronized (bufferLock) {
if (bufferIndex == bufferLast) return null;
return new String(readBytes());
}
byte b[] = readBytes();
if (b == null) return null;
return new String(b);
}