[comp.lang.c] Re^2: Discarded Function Values

steve@groucho.ucar.edu (Steve Emmerson) (11/22/89)

diamond@csl.sony.co.jp (Norman Diamond) writes:

>What DO you do about calls to malloc?

1) Put something like this in /usr/lib/lint/llib-lc and regenerate llib-lc.ln:

    void  lint_malloc(n) unsigned n; { n = n; }

2) Put something like this in /usr/include/malloc.h (if you have one):

    #ifdef lint
    #   define  malloc(x)       (lint_malloc(x), 0)
    #else
        extern char             *malloc();
    #endif

-----
Steve Emmerson		steve@unidata.ucar.edu