jxsl13 / TeeworldsEconDiscordModerationBot

small tool to moderate multiple zCatch servers via econ and discord.
10 stars 0 forks source link

data race #6

Open jxsl13 opened 4 years ago

jxsl13 commented 4 years ago
WARNING: DATA RACE
Read at 0x00c000312150 by goroutine 46:
  main.(*server).PlayerByIP()
      /home/jxsl13.tw/tools/TeeworldsEconDiscordModerationBot/server.go:265 +0xeb
  main.voteReactionsRoutine()
      /home/jxsl13.tw/tools/TeeworldsEconDiscordModerationBot/main.go:880 +0xc65

Previous write at 0x00c000312150 by goroutine 58:
  main.(*server).ParseLine()
      /home/jxsl13.tw/tools/TeeworldsEconDiscordModerationBot/server.go:161 +0x8d0
  main.parseEconLine()
      /home/jxsl13.tw/tools/TeeworldsEconDiscordModerationBot/main.go:233 +0xc8
  main.serverRoutine()
      /home/jxsl13.tw/tools/TeeworldsEconDiscordModerationBot/main.go:988 +0x936

Goroutine 46 (running) created at:
  main.handleMessageReactions()
      /home/jxsl13.tw/tools/TeeworldsEconDiscordModerationBot/main.go:718 +0x8e9
  main.serverRoutine()
      /home/jxsl13.tw/tools/TeeworldsEconDiscordModerationBot/main.go:999 +0xb04

Goroutine 58 (running) created at:
  main.handleModerate()
      /home/jxsl13.tw/tools/TeeworldsEconDiscordModerationBot/main.go:529 +0x443
  main.main.func1()
      /home/jxsl13.tw/tools/TeeworldsEconDiscordModerationBot/main.go:1142 +0x22b5
  github.com/bwmarrin/discordgo.messageCreateEventHandler.Handle()
      /home/jxsl13.tw/go/pkg/mod/github.com/bwmarrin/discordgo@v0.20.2/eventhandlers.go:497 +0x69
jxsl13 commented 4 years ago

testing