-
Notifications
You must be signed in to change notification settings - Fork 30
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
Commit 4f79ba4: Build Errors Affect Usage? #74
Comments
You can ignore it. |
I've just been pinged about this (not actually a maintainer currently) - for reference I don't get any warnings compiling udevil, even with CFLAGS='-Wunused-result'. |
Forgot to mention the obvious: gcc (Debian 6.3.0-10) 6.3.0 20170321 |
Commit d73166c. Errors persist. gcc (Arch 6.3.1-2) 6.3.1. Full build log:
|
OK, so perhaps it will start failing in the same way when Devuan gets the next gcc. I'll add a task to check. |
Even testing this with gcc-7 is producing no errors, presumably this is the correct way to do it:
So I'm going to leave this ticket alone until someone with a better understanding emerges. |
Compilers do differ on this, but those are valid warnings as those functions' return values are probably ignored. Those warnings do not affect the function of the build, and the values were ignored deliberately as non-critical (usually if those were going to fail, earlier tests will fail, so error traps are practically useless at that point). They are so commonly non-critical that I think some compilers ignore them, or are setup to do so. Usually the cleanest way to clear these is to just assign the return values to shut the compiler up. Probably a quick review of the nearby code would be a good idea too, to see why those return values were treated that way, but that's usually the case. |
Yes, but in this case the compiler has been explicitly configured to warn on unused values, and it isn't. Looking at the first example given, udevil definitely is ignoring the return value of seteuid, so gcc is failing to pay attention to its configuration here (presumably something else is in play). This is as far as I want to take it without being a maintainer.
If I was to become a maintainer, I'd fight the latter first, then go through udevil and try to do something sensible with the return values (likely overkill anyway). |
Void linux here! (gcc 7.3.0)
|
These are not errors, they are warnings - they don't affect your ability to use or build the program. |
ok, thank you @OmegaPhil |
Specifically, see the maintainer's comment: #74 (comment) |
The text was updated successfully, but these errors were encountered: