Skip to content

Commit

Permalink
Fix regression where viewer cannot update its IP address to 3DS
Browse files Browse the repository at this point in the history
  • Loading branch information
xzn committed Feb 4, 2024
1 parent 0e8fbe0 commit ad1c805
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion include/constants.h
Expand Up @@ -69,8 +69,9 @@ static const u32 IoBasePdc = 0x10400000 + 0x80000000;

#define NS_MENU_LISTEN_PORT (8000)
#define NS_HOOK_LISTEN_PORT (5000)
#define NWM_INIT_SRC_PORT (8000)
#define NWM_INIT_SRC_PORT (8001)
#define NWM_INIT_DST_PORT (8001)
#define RP_SRC_PORT (8000)
#define RP_DST_PORT_DEFAULT (8001)
#define RP_THREAD_PRIO_DEFAULT (0x10)
#define RP_CORE_COUNT_MAX (3)
Expand Down
2 changes: 1 addition & 1 deletion source/nwm/rp_nwm.c
Expand Up @@ -187,7 +187,7 @@ static uint16_t ip_checksum(void *vdata, size_t length) {

static int initUDPPacket(u8 *rpNwmBufferCur, int dataLen) {
dataLen += 8;
*(u16*)(rpNwmBufferCur + 0x22 + 8) = htons(8000); // src port
*(u16*)(rpNwmBufferCur + 0x22 + 8) = htons(RP_SRC_PORT); // src port
*(u16*)(rpNwmBufferCur + 0x24 + 8) = htons(ALR(&rpConfig->dstPort)); // dest port
*(u16*)(rpNwmBufferCur + 0x26 + 8) = htons(dataLen);
*(u16*)(rpNwmBufferCur + 0x28 + 8) = 0; // no checksum
Expand Down

0 comments on commit ad1c805

Please sign in to comment.