Skip to content

Commit

Permalink
Merge pull request #2 from zoeyjodon/n3ds/reduce-mtu
Browse files Browse the repository at this point in the history
Reduce 3DS MTU
  • Loading branch information
zoeyjodon authored Dec 7, 2023
2 parents f933fb4 + f24f4f7 commit ab5100c
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
4 changes: 2 additions & 2 deletions include/enet/protocol.h
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/**
/**
@file protocol.h
@brief ENet protocol
*/
Expand All @@ -10,7 +10,7 @@
enum
{
ENET_PROTOCOL_MINIMUM_MTU = 576,
#ifdef __WIIU__
#if defined(__WIIU__) || defined(__3DS__)
ENET_PROTOCOL_MAXIMUM_MTU = 1400,
#else
ENET_PROTOCOL_MAXIMUM_MTU = 4096,
Expand Down
4 changes: 4 additions & 0 deletions unix.c
Original file line number Diff line number Diff line change
Expand Up @@ -469,7 +469,11 @@ enet_socket_get_option (ENetSocket socket, ENetSocketOption option, int * value)
{
case ENET_SOCKOPT_ERROR:
len = sizeof (int);
#ifndef __3DS__ //getsockopt is unreliable on 3DS
result = getsockopt (socket, SOL_SOCKET, SO_ERROR, value, & len);
#else
result = 0;
#endif
break;

case ENET_SOCKOPT_TTL:
Expand Down

0 comments on commit ab5100c

Please sign in to comment.