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

rpmlint: W: shared-lib-calls-exit /usr/lib64/libvalidator.so.0.9.0 exit@GLIBC_2.2.5 #20

Open
mgeisler opened this issue Feb 26, 2014 · 3 comments
Assignees

Comments

@mgeisler
Copy link
Contributor

When building RPM packages, I see a warning from rpmlint:

W: shared-lib-calls-exit /usr/lib64/libvalidator.so.0.9.0 exit@GLIBC_2.2.5

This library package calls exit() or _exit(), probably in a non-fork() context. Doing so from a library is strongly discouraged - when a library function calls exit(), it prevents the calling program from handling the error, reporting it to the user, closing files properly, and cleaning up any state that the program has. It is preferred for the library to return an actual error code and let the calling program decide how to handle the situation.

Can someone tell me if this warning is a false positive or if we should fix the calls to exit and _exit?

@bortoq
Copy link
Member

bortoq commented Feb 26, 2014

i don't see warning when building my sources (not sure about ron's sources). and yes, the code contains "exit"s

@pkit
Copy link
Member

pkit commented Feb 26, 2014

These are the functionas that call exit() or _exit()

NaClExit (this one is false positive, as it is not called ever, although it's strange why it's even linked into libvalidator then)

NCDecoderStateSetErrorReporter
NaClValidatorStateSetErrorReporter
NaClInstIterFatal
NaClFatal

All of these can be fixed either by doing something meaningful, or by changing all exists into asserts.

@mgeisler
Copy link
Contributor Author

Sorry, I should probably have been more explicit about where the rpmlint output is. It's on the openSUSE Build Service where I'm currently testing building RPMs on some random distributions: https://build.opensuse.org/package/show/home:mgeisler/zvm-validator

Click the "Rpmlint Results" tab to see them.

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

No branches or pull requests

3 participants