Skip to content

Commit 27dc45a

Browse files
committed
NET_Init() should fail in the stub library
This allows applications to know up front that networking is not available.
1 parent 3b412a4 commit 27dc45a

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/SDL_net_stub_only.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
// don't do anything. Sorry!
2525
int NET_Version(void) { return SDL_NET_VERSION; }
26-
bool NET_Init(void) { return true; }
26+
bool NET_Init(void) { return SDL_Unsupported(); }
2727
void NET_Quit(void) {}
2828
NET_Address * NET_ResolveHostname(const char *host) { SDL_Unsupported(); return NULL; }
2929
NET_Status NET_WaitUntilResolved(NET_Address *address, Sint32 timeout) { SDL_Unsupported(); return NET_FAILURE; }

0 commit comments

Comments
 (0)