Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 01 Dec 2014 11:53:44 +0000
From:      bugzilla-noreply@freebsd.org
To:        freebsd-bugs@FreeBSD.org
Subject:   [Bug 195551] New: [patch] cap_getaddrinfo() doesn't work
Message-ID:  <bug-195551-8@https.bugs.freebsd.org/bugzilla/>

next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=195551

            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@FreeBSD.org
          Reporter: mp39590@gmail.com

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

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.



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