Skip to content
New issue

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

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

Already on GitHub? # to your account

Return value of lf_critical_section_enter() and exit() are inconsistent #135

Closed
edwardalee opened this issue Jan 6, 2023 · 1 comment · Fixed by #136
Closed

Return value of lf_critical_section_enter() and exit() are inconsistent #135

edwardalee opened this issue Jan 6, 2023 · 1 comment · Fixed by #136
Assignees

Comments

@edwardalee
Copy link
Contributor

In platform.h, these functions are defined:

extern int lf_critical_section_enter();
extern int lf_critical_section_exit();

However, reactor.c discards the return value:

void _lf_critical_section_enter() {
    lf_critical_section_enter();
}
void _lf_critical_section_exit() {
    lf_critical_section_exit();
}

Shouldn't _lf_critical_section_enter and exit return an int consistently? And shouldn't the return value be checked?

@erlingrj
Copy link
Collaborator

erlingrj commented Jan 6, 2023

I agree, I will address this.

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants