|
@@ -812,7 +812,8 @@ typedef struct {
|
|
|
bool disableTlsVerification;
|
|
|
const char **protocols;
|
|
|
int protocolsCount;
|
|
|
- int pingInterval;
|
|
|
+ int connectionTimeoutMs;
|
|
|
+ int pingIntervalMs;
|
|
|
int maxOutstandingPings;
|
|
|
} rtcWsConfiguration;
|
|
|
```
|
|
@@ -826,7 +827,8 @@ Arguments:
|
|
|
- `disableTlsVerification`: if true, don't verify the TLS certificate, else try to verify it if possible
|
|
|
- `protocols` (optional): an array of pointers on null-terminated protocol names (NULL if unused)
|
|
|
- `protocolsCount` (optional): number of URLs in the array pointed by `protocols` (0 if unused)
|
|
|
- - `pingInterval` (optional): ping interval in milliseconds (0 if default, < 0 if disabled)
|
|
|
+ - `connectionTimeoutMs` (optional): connection timeout in milliseconds (0 if default, < 0 if disabled)
|
|
|
+ - `pingIntervalMs` (optional): ping interval in milliseconds (0 if default, < 0 if disabled)
|
|
|
- `maxOutstandingPings` (optional): number of unanswered pings before declaring failure (0 if default, < 0 if disabled)
|
|
|
|
|
|
Return value: the identifier of the new WebSocket or a negative error code
|
|
@@ -894,6 +896,7 @@ typedef struct {
|
|
|
const char *certificatePemFile;
|
|
|
const char *keyPemFile;
|
|
|
const char *keyPemPass;
|
|
|
+ int connectionTimeoutMs;
|
|
|
} rtcWsServerConfiguration;
|
|
|
```
|
|
|
|
|
@@ -907,6 +910,7 @@ Arguments:
|
|
|
- `certificatePemFile` (optional): PEM certificate or path of the file containing the PEM certificate (`NULL` for an autogenerated certificate)
|
|
|
- `keyPemFile` (optional): PEM key or path of the file containing the PEM key (`NULL` for an autogenerated certificate)
|
|
|
- `keyPemPass` (optional): PEM key file passphrase (NULL if no passphrase)
|
|
|
+ - `connectionTimeoutMs` (optional): connection timeout in milliseconds (0 if default, < 0 if disabled)
|
|
|
- `cb`: the callback for incoming client WebSocket connections (must not be `NULL`)
|
|
|
|
|
|
`cb` must have the following signature: `void rtcWebSocketClientCallbackFunc(int wsserver, int ws, void *user_ptr)`
|