case "ARC:":
ARC = cols[1]
case "Swap:":
- if cols[4] == "Used," {
+ if len(cols) >= 5 && cols[4] == "Used," {
Swap = cols[3] + " Swap "
} else {
Swap = ""
func main() {
xsetroot := flag.Bool("xsetroot", false, "Call xsetroot")
- iodevs := flag.String("iodevs", "ada0 ada1", "iostat devices")
+ iodevs := flag.String("iodevs", "nvd0 nvd1", "iostat devices")
refresh := flag.Uint("refresh", 2, "Refresh interval")
flag.Parse()
N = strconv.Itoa(int(*refresh))