Menu

#44 wrong definition for unsetenv in libcompat

closed-accepted
nobody
None
5
2012-11-13
2012-10-26
Anonymous
No

The definition of unsetenv in lib/unsetenv.c does not have the same return value as the call should have. The version in libcompat returns void, but it should return int.

Although using the unsetenv in libcompat is really only an assert, on platforms where it is necessary compiling fails as at lesat one unit test uses unsetenv and expects it to return an int.

This small patch corrects the version in src/unsetenv.c to return an int.

This was observed compiling check in cygwin. With this patch (and the osx patch for the clock_gettime() fix) cygwin will compile check. The unit tests do not pass though.

Discussion

  • Fredrik Hugosson

    • status: open --> closed-accepted
     

Log in to post a comment.