Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

lwip: Use modulo operator for mbox #684

Merged
merged 1 commit into from
Nov 25, 2024

Conversation

Ryzee119
Copy link
Contributor

Was getting some corruption in the lwip mboxes. This is a bug and the code should be the modulo operator not bitwise AND.

The below code demonstrates the issue

static void my_tcpip_callback1(void *param){
    DbgPrint("I work\n"):
} 

static void my_tcpip_callback2(void *param){
    DbgPrint("I don't work\n"):
}

nxNetInit(NULL);
tcpip_callback(my_tcpip_callback1, NULL); // This works by chance as mbox position is zero.
tcpip_callback(my_tcpip_callback2, NULL); // This doesnt work

@Ernegien Ernegien merged commit f133d5c into XboxDev:master Nov 25, 2024
6 checks passed
@Ryzee119 Ryzee119 deleted the nvnet_sys_arch_fix branch November 25, 2024 06:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants