The time to wait for a server to respond to a connection request.
BASS_SetConfig( BASS_CONFIG_NET_TIMEOUT, DWORD timeout );
timeout | The time to wait, in milliseconds. |
The BASS_CONFIG_THREAD flag can be used to make the setting specific to the current thread. When that is not 0, it will override the global setting in the current thread.
When playlist processing is enabled via the BASS_CONFIG_NET_PLAYLIST option, the timeout applies to each playlist entry rather than the playlist as a whole.
BASS_SetConfig(BASS_CONFIG_NET_TIMEOUT, 3000);
Set the timeout to 3 seconds only for one stream in the current thread.
BASS_SetConfig(BASS_CONFIG_NET_TIMEOUT | BASS_CONFIG_THREAD, 3000); // set the thread's timeout HSTREAM stream = BASS_StreamCreateURL(url, 0, 0, NULL, NULL); BASS_SetConfig(BASS_CONFIG_NET_TIMEOUT | BASS_CONFIG_THREAD, 0); // reset to the global timeout