View Issue Details

IDProjectCategoryView StatusLast Update
0003461libmicrohttpdbuild systempublic2014-10-05 01:19
Reporteramatus Assigned ToChristian Grothoff  
PrioritynormalSeverityminorReproducibilityhave not tried
Status closedResolutionfixed 
Product Version0.9.37 
Target Version0.9.38Fixed in Version0.9.38 
Summary0003461: The microhttpd.h header file declares symbols that may not be present in the built library
DescriptionThe microhttpd.h header file declares MHD_create_post_processor but if the library is built without HAVE_POSTPROCESSOR these symbols will be missing from the library. A user of MHD_create_post_processor will not notice the problem until run time.
Either MHD_create_post_processor (and symbols like it) need to be always defined, possibly by stub functions if the feature is disabled, and the user can handle the missing feature at run time, or the header file needs to be dynamically generated to not include the symbols, and the user can handle the missing feature at compile time.
TagsNo tags attached.

Activities

Christian Grothoff

2014-07-01 10:17

manager   ~0008491

If we put in stubs, the user will also only notice the issue at runtime (just with a failure code when using the API, instead of a linker error). In practice, I suspect the result will be the same: a broken application.

Changing the header similarly is not a universal answer, as obviously I can compile an application against one version of the API and then at runtime link against a different build of MHD. And library versioning won't help here, as that can and always will ONLY be valid if you do not muck with configure options to disable features.

In general the documentation has always said that distributions MUST NOT disable features, and that those flags are ONLY for developers on embedded systems who know what they are doing. So really, a libmicrohttpd.so without the postprocessor is simply a broken build.

amatus

2014-07-01 14:26

reporter   ~0008493

Gentoo managed to produce a broken libmicrohttpd.so. Perhaps a loud warning at the end of the configure script will get more attention than the documentation.

Christian Grothoff

2014-07-01 19:32

manager   ~0008495

Fixed in SVN 33889.

Issue History

Date Modified Username Field Change
2014-06-30 20:26 amatus New Issue
2014-07-01 10:14 Christian Grothoff Assigned To => Christian Grothoff
2014-07-01 10:14 Christian Grothoff Status new => assigned
2014-07-01 10:17 Christian Grothoff Note Added: 0008491
2014-07-01 14:26 amatus Note Added: 0008493
2014-07-01 19:32 Christian Grothoff Note Added: 0008495
2014-07-01 19:32 Christian Grothoff Status assigned => resolved
2014-07-01 19:32 Christian Grothoff Fixed in Version => 0.9.38
2014-07-01 19:32 Christian Grothoff Resolution open => fixed
2014-07-01 19:33 Christian Grothoff Target Version => 0.9.38
2014-10-05 01:19 Christian Grothoff Status resolved => closed