DataChannel: how to know the max size of the sending buffer?

Hi, according to the spec (and this is the same for WebSocket):

"if the data cannot be sent, e.g. because it would need to be buffered
but the buffer is full, the user agent must abruptly close channel’s
underlying data transport with an error."

OK, I can check the current buffered data size via
socket.bufferedAmount. But, how may I know the buffer value that would
cause send() to fail *without* calling send()?

If the buffer size is not standardized, shouldn't the API provide a getter?

Thanks a lot.

-- 
Iñaki Baz Castillo
<ibc@aliax.net>

Received on Wednesday, 7 May 2014 15:20:16 UTC