On Mon, 25 Jan 2010 22:17:40 +0100 Magnus wrote: MF> On Mon, 2010-01-25 at 16:01 +0000, [email protected] wrote: MF> > move snmp_get_statistic helper to helpers dir; update all_helpers header MF> MF> I have to question this. MF> MF> The reason I originally had to put it in mibgroup/utilities and not put MF> the header under include/ was that it is so specialized it is utterly MF> unusable for anything save mib modules that export internal statistics MF> variables, so why build it if no such module is built?
Well, given that the helper is used for mibII statistics, one of the most basic mibs, I'd say that it will more likely be used than not. Also, the cod savings would be minimal (the file is only three short functions). And lastly, we have a directory explicity named for helpers, so that's where I'd expect to find a helper. MF> By the way, why put the range check in the handler instead of the MF> registration function and then let the scalar_group helper handle the MF> range checking? because the scalar_group helper doesn't have any idea what the max is for the statistics array, it only knows about the range 1..N for the group. It doesn't know anything about the offset being added by the statistics handler. That being said, I do think the range check could be moved to the registration, so that the registration would fail if the the max would be exceeded... ------------------------------------------------------------------------------ Download Intel® Parallel Studio Eval Try the new software tools for yourself. Speed compiling, find bugs proactively, and fine-tune applications for parallel performance. See why Intel Parallel Studio got high marks during beta. http://p.sf.net/sfu/intel-sw-dev _______________________________________________ Net-snmp-coders mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/net-snmp-coders
