MCPcopy Create free account
hub / github.com/NVIDIAGameWorks/PhysX / read

Method read

physx/source/foundation/src/unix/PsUnixSocket.cpp:319–330  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

317}
318
319uint32_t SocketImpl::read(uint8_t* data, uint32_t length)
320{
321 if(length == 0)
322 return 0;
323
324 int32_t received = recv(mSocket, reinterpret_cast<char*>(data), int32_t(length), 0);
325
326 if(received <= 0 && !nonBlockingTimeout())
327 disconnect();
328
329 return uint32_t(received > 0 ? received : 0);
330}
331
332class BufferedSocketImpl : public SocketImpl
333{

Callers 1

readDataMethod · 0.45

Calls 1

isConnectedMethod · 0.45

Tested by

no test coverage detected