Index | Thread | Search

From:
Martijn van Duren <openbsd+tech@list.imperialat.at>
Subject:
Re: snmpd: move engineid into a struct
To:
Theo Buehler <tb@theobuehler.org>
Cc:
tech@openbsd.org, Jonathan Matthew <jonathan@d14n.org>
Date:
Wed, 24 Dec 2025 16:00:51 +0100

Download raw body.

Thread
  • Theo Buehler:

    snmpd: move smi_getticks to appl_sysuptime

  • 
    On 12/24/25 15:54, Theo Buehler wrote:
    > On Mon, Dec 22, 2025 at 12:16:43PM +0100, Martijn van Duren wrote:
    >> On 11/9/25 12:51, Martijn van Duren wrote:
    >>> This diff is a bit of preparation for the next diff.
    >>> Initially I went a bit too simplistic and simply put the engineid value
    >>> and length in two separate variables inside the requiring structs. This
    >>> diff bundles the 2 variables into a struct engineid. This also helps with the
    >>> parse.y stuff.
    >>>
    >>> This diff is on top of the "move smi_getticks to appl_sysuptime" diff.
    >>> It might apply without it, but not tested.
    >>>
    >>> OK?
    >>>
    >>> martijn@
    >>>
    >> Updated diff. jmatthew@ found that the pen vanished from the engineid.
    >> Simplified the problem boils down to this:
    >> foo: bar {
    >> 	$$[0] = 1;
    >> } baz {
    >> 	$$[1] = 2
    >> }
    >> Where I expected the result to be {1, 2}, but I got {0, 2}. I merged
    >> the two bodies, which gives a cleaner result anyway, but I'm still
    >> curious how this is supposed to work. If anyone has an idea, feel free
    >> to speak up.
    > 
    > Is the engine.c in the diff below the latest version? There was a
    > missing cvs add and the tree is broken with
    > 
    > ===> usr.sbin/snmpd
    > make: don't know how to make engine.c (prerequisite of: engine.o)
    > Stop in usr.sbin/snmpd
    > 
    Yep, overlooked that one. Committed now. Sorry for that.
    
    
  • Theo Buehler:

    snmpd: move smi_getticks to appl_sysuptime