MCPcopy Create free account
hub / github.com/F-Stack/f-stack / sysctl_handle_int

Function sysctl_handle_int

freebsd/kern/kern_sysctl.c:1599–1621  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1597 */
1598
1599int
1600sysctl_handle_int(SYSCTL_HANDLER_ARGS)
1601{
1602 int tmpout, error = 0;
1603
1604 /*
1605 * Attempt to get a coherent snapshot by making a copy of the data.
1606 */
1607 if (arg1)
1608 tmpout = *(int *)arg1;
1609 else
1610 tmpout = arg2;
1611 error = SYSCTL_OUT(req, &tmpout, sizeof(int));
1612
1613 if (error || !req->newptr)
1614 return (error);
1615
1616 if (!arg1)
1617 error = EPERM;
1618 else
1619 error = SYSCTL_IN(req, arg1, sizeof(int));
1620 return (error);
1621}
1622
1623/*
1624 * Based on on sysctl_handle_int() convert milliseconds into ticks.

Callers 15

param_set_arc_intFunction · 0.85
param_set_slop_shiftFunction · 0.85
sysctl_ipfw_table_numFunction · 0.85
sysctl_ipfw_tables_setsFunction · 0.85
ipfw_chg_hookFunction · 0.85
sysctl_hash_sizeFunction · 0.85
sysctl_ieee80211_alq_logFunction · 0.85
amrr_sysctl_intervalFunction · 0.85
rssadapt_sysctl_intervalFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected