1
0
Fork 0
mirror of https://github.com/FrankerFaceZ/FrankerFaceZ.git synced 2025-09-16 01:56:55 +00:00

Fix a data race

This commit is contained in:
Kane York 2015-12-16 11:58:48 -08:00
parent 717acb3e40
commit 405ad22372
3 changed files with 11 additions and 2 deletions

View file

@ -59,6 +59,15 @@ type StatsData struct {
// I don't really care.
var Statistics = newStatsData()
var CommandCounter = make(chan Command, 10)
func commandCounter() {
for cmd := range CommandCounter {
Statistics.CommandsIssuedTotal++
Statistics.CommandsIssuedMap[cmd]++
}
}
const StatsDataVersion = 5
const pageSize = 4096