[ofa-general] NULL isn't defined in dat_strerror.c

Harold/Carlyn Iuzzolino iuzzolin at nmia.com
Tue Aug 5 01:29:50 PDT 2008


Dear Openfabrics,  general at lists.openfabrics.org         

Summary of bug: In subroutine dat_strerror.c NULL isn't defined.

[root at treebeard BUILD]# uname -a
Linux treebeard 2.6.25-14.fc9.x86_64 #1 SMP Thu May 1 06:06:21 EDT 2008 x86_64 x86_64 x86_64 GNU/Linux

In /tmp/OFED.16989.logs/compat-dapl.rpmbuild.log, compilation stops with the
following complaint:

 gcc -DHAVE_CONFIG_H -I. -I. -I. -Wall -g -D_GNU_SOURCE -DOS_RELEASE=131078 -I./dat/include/ -I./dat/udat/ -I./dat/udat/linux -I./dat/common/ -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic -MT dat_udat_libdat_la-dat_strerror.lo -MD -MP -MF .deps/dat_udat_libdat_la-dat_strerror.Tpo -c dat/common/dat_strerror.c  -fPIC -DPIC -o
.libs/dat_udat_libdat_la-dat_strerror.o

dat/common/dat_strerror.c: In function 'dat_strerror':
dat/common/dat_strerror.c:621: error: 'NULL' undeclared (first use in this function)
dat/common/dat_strerror.c:621: error: (Each undeclared identifier is reported only once
dat/common/dat_strerror.c:621: error: for each function it appears in.)
make[2]: *** [dat_udat_libdat_la-dat_strerror.lo] Error 1



In the directory
/var/tmp/OFED_topdir/BUILD/compat-dapl-1.2.8/dat/common/

The following files use NULL.

[root at treebeard common]# grep -l NULL *c
dat_api.c
dat_dictionary.c
dat_dr.c
dat_sr.c
dat_strerror.c

Here are the include files used in those subroutines:

[root at treebeard common]# grep include *c
dat_api.c:#include "dat_osd.h"
dat_api.c:#include "dat_init.h"
dat_api.c:#include <dat/dat_registry.h>
dat_dictionary.c:#include "dat_dictionary.h"
dat_dr.c:#include "dat_dr.h"
dat_dr.c:#include "dat_dictionary.h"
dat_sr.c:#include "dat_sr.h"
dat_sr.c:#include "dat_dictionary.h"
dat_sr.c:#include "udat_sr_parser.h"
dat_strerror.c:#include <dat/kdat.h>
dat_strerror.c:#include <dat/udat.h>


Which of those .h files do you need to include in dat_strerror.c so that
NULL gets defined?


Carlyn Iuzzolino



More information about the general mailing list