[Bug 195551] New: [patch] cap_getaddrinfo() doesn't work

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Mon Dec 1 11:53:44 UTC 2014


            Bug ID: 195551
           Summary: [patch] cap_getaddrinfo() doesn't work
           Product: Base System
           Version: 11.0-CURRENT
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Some People
          Priority: ---
         Component: bin
          Assignee: freebsd-bugs at FreeBSD.org
          Reporter: mp39590 at gmail.com

Created attachment 150064
  --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=150064&action=edit

cap_getaddrinfo() from casper daemon doesn't work and returns error about badly
formatted hints structure.

There are following errors:

 1. When passing hints structure to native getaddrinfo() ai_next member
wasn't set to NULL, and because of it getaddrinfo() failed, since it
requires everything to be set to 0 or NULL. From the man page:

"All other elements of the addrinfo structure passed via hints must be
zero or the null pointer."

2. nvlist_add_string was trying to add ai->ai_canonname field from
getaddrinfo() response, but it could be NULL and nvlist was going into
'error 22' state after this.

I've also added test cases for cap_getaddrinfo() for regression tests.

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

More information about the freebsd-bugs mailing list