On Fri, 04 Dec 2020 20:15:13 -0800 Greg Steuck <gne...@openbsd.org> wrote:
> George Koehler <kern...@gmail.com> writes: > > > If I do ddb set a bad value, then sysctl refuses to show the value: > > > > # sysctl ddb.console=1 > > ddb.console: 0 -> 1 > > # sysctl ddb.trigger=1 > > Stopped at ddb_sysctl+0x114: ori r0,r0,0x0 > > ddb{0}> set $radix = 0t2 > > ddb{0}> c > > ddb.trigger: 0 -> 1 > > # sysctl ddb.radix > > sysctl: ddb.radix: Invalid argument > > > > This diff might be better than doing nothing? I'm not sure. --George > > I'm game for changing the range of ddb.radix to [2..INT_MAX] if you > think that's better. I doubt it makes that much of a difference either > way. I prefer to keep [8..16]; your ddb_sysctl diff from Nov 30 is now ok gkoehler@ The only good $radix values are 8, 10, 16. I might want to restrict both "sysctl ddb.radix=" and "ddb> set $radix =" to 8, 10, 16; but I have not written the code to restrict them. Your diff restricts only "sysctl ddb.radix=" to [8..16], which is easy with sysctl_bounded_args and without my needing to write more code. Your diff is better than nothing. I'm sorry that I took so long to give the ok.