mirror of
https://github.com/libretro/RetroArch
synced 2025-04-02 07:20:34 +00:00
(network gfx) Cleanup
This commit is contained in:
parent
c7c7d0988e
commit
861262ef3a
@ -16,6 +16,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include <retro_miscellaneous.h>
|
#include <retro_miscellaneous.h>
|
||||||
|
#include <retro_timers.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <compat/strl.h>
|
#include <compat/strl.h>
|
||||||
|
|
||||||
@ -45,7 +46,7 @@
|
|||||||
#define str(s) #s
|
#define str(s) #s
|
||||||
|
|
||||||
enum {
|
enum {
|
||||||
NETWORK_VIDEO_PIXELFORMAT_RGBA8888,
|
NETWORK_VIDEO_PIXELFORMAT_RGBA8888 = 0,
|
||||||
NETWORK_VIDEO_PIXELFORMAT_BGRA8888,
|
NETWORK_VIDEO_PIXELFORMAT_BGRA8888,
|
||||||
NETWORK_VIDEO_PIXELFORMAT_RGB565
|
NETWORK_VIDEO_PIXELFORMAT_RGB565
|
||||||
} network_video_pixelformat;
|
} network_video_pixelformat;
|
||||||
@ -124,7 +125,7 @@ try_connect:
|
|||||||
{
|
{
|
||||||
int ret = socket_connect(fd, (void*)next_addr, true);
|
int ret = socket_connect(fd, (void*)next_addr, true);
|
||||||
|
|
||||||
if (ret >= 0)// && socket_nonblock(fd))
|
if (ret >= 0) /* && socket_nonblock(fd)) */
|
||||||
break;
|
break;
|
||||||
|
|
||||||
socket_close(fd);
|
socket_close(fd);
|
||||||
@ -138,14 +139,16 @@ try_connect:
|
|||||||
|
|
||||||
network->fd = fd;
|
network->fd = fd;
|
||||||
|
|
||||||
//socket_nonblock(network->fd);
|
#if 0
|
||||||
|
socket_nonblock(network->fd);
|
||||||
|
#endif
|
||||||
|
|
||||||
if (network->fd > 0)
|
if (network->fd > 0)
|
||||||
RARCH_LOG("[network]: Connected to host.\n");
|
RARCH_LOG("[network]: Connected to host.\n");
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
RARCH_LOG("[network]: Could not connect to host, retrying...\n");
|
RARCH_LOG("[network]: Could not connect to host, retrying...\n");
|
||||||
usleep(1000 * 1000);
|
retro_sleep(1000);
|
||||||
goto try_connect;
|
goto try_connect;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user