• David Gibson's avatar
    ccan: Correct some poor conventions in _info includes · 291237b4
    David Gibson authored
    There are a couple of small problems with the includes used in most of
    ccan's _info files.
    
       * _info routinely uses printf(), and so should include <stdio.h>, but
    only some of them do.  We get away with it, because they do include
    <string.h>, which apparently includes <stdio.h> indirectly, but we should
    be explicit about it.
    
       * Most _info files were including config.h after the system headers.
    That _seems_ sensible, but actually causes problems.  Because config.h
    defines _GNU_SOURCE it can change the behaviour of the system headers.
    More specifically it can make them behave differently to how the individual
    module headers (which have included config.h) expects them to behave.
    
    This patch adjusts all the existing _info files and, more importantly,
    the template constructed by ccanlint.
    Signed-off-by: default avatarDavid Gibson <david@gibson.dropbear.id.au>
    Signed-off-by: default avatarRusty Russell <rusty@rustcorp.com.au>
    291237b4
_info 1.32 KB