LIST_END doesn't exist at queue.h

Ed Schouten ed at
Sun May 27 21:48:49 UTC 2007


* Josep Pujadas i Jubany <josep at> wrote:
> Hello!
> I can't compile snort2c ( on FreeBSD 6.2 ...
> # make 
> Warning: Object directory not changed from 
> original /usr/home/super/snort_pf/snort2c-0.2/snort2c 
> cc -O2 -fno-strict-aliasing -pipe  -Wall -Werror -g -O2  -c parser.c 
> parser.c: In function `s2c_parse_free_wl': 
> parser.c:283: warning: implicit declaration of function `LIST_END' 
> parser.c:283: warning: comparison between pointer and integer 
> *** Error code 1 
> Stop in /usr/home/super/snort_pf/snort2c-0.2/snort2c. 
> The package is designed for working with OpenBSD, where LIST_END exists 
> for queue.h
> I looked at my /usr/include/sys/queue.h and at man queue and LIST_END is not 
> supported.
> Any idea?

If I understand the manual page correctly, LIST_END(head) is nothing
more than some portable way to handle sentinels at the end of the list.
Just smack the following code above the C file:

| #ifndef LIST_END
| #define LIST_END(head) NULL
| #endif

This is exactly the same as how it is defined in OpenBSD's sys/queue.h:

 Ed Schouten <ed at>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 187 bytes
Desc: not available
Url :

More information about the freebsd-current mailing list