void myqtt_conn_timeout ( MyQttCtx ctx,
long  microseconds_to_wait 
)

Allows to configure myqtt internal timeouts for synchronous operations.

This function allows to set the timeout to use on new connection creation. Default timeout is defined to 60 seconds (60 x 1000000 = 60000000 microseconds).

If you call to create a new connection with myqtt_conn_new and remote peer doesn't responds within the period, myqtt_conn_new will return with a non-connected myqtt connection.

Parameters
ctxThe context where the operation will be performed.
microseconds_to_waitTimeout value to be used. Providing a value of 0, will reset the timeout to the default value.

References myqtt_support_setenv(), and myqtt_support_unsetenv().