Re: [head tinderbox] failure on amd64/amd64

From: Hiroki Sato <hrs_at_FreeBSD.org>
Date: Mon, 08 Jun 2009 16:53:25 +0900 (JST)
Eygene Ryabinkin <rea-fbsd_at_codelabs.ru> wrote
  in <sqWp8ZLqcJhvIOZAWr3MfqIXJ9k_at_XX1fo6zQUfC4h0jjRC6IBz3oNH4>:

re> Mon, Jun 08, 2009 at 11:00:56AM +0400, Eygene Ryabinkin wrote:
re> > Looks like that
re> > -----
re> > 		ifr->ifr_data = (caddr_t)(size_t)options;
re> > -----
re> > will be more correct and will disable this warning -- it will convert
re> > u_int to the proper type that will be able to carry addresses for the
re> > given platform.
re>
re> Hmm, looking a bit into the code of gif_ioctl, I am under impression
re> that 'options' will not be initialized at the GIFSOPTS processing.
re> And the statement
re> -----
re>                 if ((error = copyin(&options, &sc->gif_options,
re>                                 sizeof(sc->gif_options)))) {
re> -----
re> looks strange -- (&options) is in the kernel space (stack space),
re> so why one is passing it as the userland address?  Judging by the
re> contents of newly added setgifopts() inside ifgif.c, I would assume
re> that one wants 'ifr->ifr_data' instead of '&options'.
re>
re> Am I missing something?

 Gr, certainly this looks strange.  I meant the attached patch.
 Thanks for pointing out it.

 I will fix the build error as soon as I return home.

-- Hiroki

Received on Mon Jun 08 2009 - 05:56:11 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:49 UTC