Fixed bug that you cannot gather data on non english systems (#1944)

This commit is contained in:
Da1den 2016-12-13 15:24:41 +01:00 committed by Cameron Sparr
parent 8e3fbaa9dd
commit 17fa6f9b17
1 changed files with 1 additions and 5 deletions

View File

@ -116,11 +116,7 @@ func (m *Win_PerfCounters) AddItem(metrics *itemList, query string, objectName s
var handle win.PDH_HQUERY
var counterHandle win.PDH_HCOUNTER
ret := win.PdhOpenQuery(0, 0, &handle)
if m.PreVistaSupport {
ret = win.PdhAddCounter(handle, query, 0, &counterHandle)
} else {
ret = win.PdhAddEnglishCounter(handle, query, 0, &counterHandle)
}
ret = win.PdhAddCounter(handle, query, 0, &counterHandle)
_ = ret
temp := &item{query, objectName, counter, instance, measurement,