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

LVRT crash was because RTSetCleanupProc was null. #114

Merged
merged 2 commits into from
Aug 19, 2022
Merged

Conversation

chadallee
Copy link
Contributor

Changed some of the way we dynamically load export symbols from liblvrt.so

@chadallee chadallee closed this Aug 18, 2022
@chadallee chadallee reopened this Aug 18, 2022
PostLVUserEvent = (PostLVUserEvent_T)dlsym(lvModule, "PostLVUserEvent");
Occur = (Occur_T)dlsym(lvModule, "Occur");
RTSetCleanupProc = (RTSetCleanupProc_T)dlsym(lvModule, "RTSetCleanupProc");
exit(grpc::StatusCode::INTERNAL);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure calling Exit is the best thing to do here. Makes it really hard to debug especially on RT. It would be better to at least console writeline something that gives a hint.

Copy link
Contributor Author

@chadallee chadallee Aug 19, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, I wasn't sure the right way to handle this error condition. I'd love to use whatever function writes to the NI error logs, but I assume that code probably lives in liblvrt.so, which is precisely what we would have failed to load.

Writing to stdout or stderr probably makes sense, but im not sure where that even shows up if you don't run 'lvrt' manually. Calling syslog() would probably be a good option, too.

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

Successfully merging this pull request may close these issues.

None yet

2 participants