File tree Expand file tree Collapse file tree 2 files changed +11
-7
lines changed Expand file tree Collapse file tree 2 files changed +11
-7
lines changed Original file line number Diff line number Diff line change @@ -10,19 +10,21 @@ import (
1010)
1111
1212const (
13- // Filesystem paths .
13+ // RuntimePath is the path where runtime files are stored .
1414 RuntimePath = "/var/run/"
15- LogPath = "/var/log/"
15+
16+ // LogPath is the path where log files are stored.
17+ LogPath = "/var/log/"
1618)
1719
1820// GetOSInfo returns OS version information.
1921func GetOSInfo () string {
2022 info , err := ioutil .ReadFile ("/proc/version" )
21- if err == nil {
22- return string (info )
23- } else {
23+ if err != nil {
2424 return "unknown"
2525 }
26+
27+ return string (info )
2628}
2729
2830// GetLastRebootTime returns the last time the system rebooted.
Original file line number Diff line number Diff line change @@ -8,9 +8,11 @@ import (
88)
99
1010const (
11- // Filesystem paths .
11+ // RuntimePath is the path where runtime files are stored .
1212 RuntimePath = ""
13- LogPath = ""
13+
14+ // LogPath is the path where log files are stored.
15+ LogPath = ""
1416)
1517
1618// GetOSInfo returns OS version information.
You can’t perform that action at this time.
0 commit comments