Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 06 Apr 2025 22:02:13 +0000
From:      bugzilla-noreply@freebsd.org
To:        bugs@FreeBSD.org
Subject:   [Bug 285924] netinet/ip.h should pull in its required type definitions
Message-ID:  <bug-285924-227@https.bugs.freebsd.org/bugzilla/>

index | next in thread | raw e-mail

https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=285924

            Bug ID: 285924
           Summary: netinet/ip.h should pull in its required type
                    definitions
           Product: Base System
           Version: Unspecified
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Many People
          Priority: ---
         Component: bin
          Assignee: bugs@FreeBSD.org
          Reporter: riggs@FreeBSD.org

The following simple program...

#include <netinet/ip.h>
int main() {
        return 0;
}

errors out when compiled:

> cc ip.c
In file included from ip.c:1:
/usr/include/netinet/ip.h:52:2: error: unknown type name 'u_char'; did you mean
'char'?
   52 |         u_char  ip_hl:4,                /* header length */
      |         ^
/usr/include/netinet/ip.h:56:2: error: unknown type name 'u_char'; did you mean
'char'?
   56 |         u_char  ip_v:4,                 /* version */
      |         ^

Shouldn't it pull in the type definitions it needs, like from sys/types.h?

-- 
You are receiving this mail because:
You are the assignee for the bug.

home | help

Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-285924-227>