fix goagent and luci-goagent bugs