func main() {
// get clock ticks, this will return the same as C.sysconf(C._SC_CLK_TCK)
clktck, err := sysconf.Sysconf(sysconf.SC_CLK_TCK)
if err != nil {
fmt.Printf("SC_CLK_TCK: %v\n", clktck)
}
}
I think the if block should execute if there is no error, i.e. if err == nil.
Currently the example is printing the value of clktck if an error occurred.
README.md has the following example:
I think the if block should execute if there is no error, i.e.
if err == nil
.Currently the example is printing the value of
clktck
if an error occurred.