Dimitry Andric 6c01c0e0c6 With clang 3.9.0, compiling sys/netinet/igmp.c results in the following
warning:

sys/netinet/igmp.c:546:21: error: implicit conversion from 'int' to 'char' changes value from 148 to -108 [-Werror,-Wconstant-conversion]
        p->ipopt_list[0] = IPOPT_RA;    /* Router Alert Option */
                         ~ ^~~~~~~~
sys/netinet/ip.h:153:19: note: expanded from macro 'IPOPT_RA'
#define IPOPT_RA                148             /* router alert */
                                ^~~

This is because ipopt_list is an array of char, so IPOPT_RA is wrapped
to a negative value.  It would be nice to change ipopt_list to an array
of u_char, but it changes the signature of the public struct ipoption,
so add an explicit cast to suppress the warning.

Reviewed by:	imp
MFC after:	3 days
Differential Revision: https://reviews.freebsd.org/D7777
2016-09-04 17:23:10 +00:00
..
2016-05-03 18:05:43 +00:00
2016-05-03 18:05:43 +00:00
2016-03-31 00:53:23 +00:00
2016-08-18 22:59:10 +00:00
2015-12-17 14:41:30 +00:00
2015-07-31 09:02:28 +00:00
2016-05-03 18:05:43 +00:00
2016-05-03 18:05:43 +00:00
2016-07-17 13:14:51 +00:00
2016-07-17 13:14:51 +00:00
2015-06-17 15:20:14 +00:00
2016-05-09 16:35:05 +00:00
2016-05-03 18:05:43 +00:00