kernel/sysctl.c: detect overflows when converting to int