agent: Fixing config merge issue

This commit is contained in:
Armon Dadgar 2014-09-02 14:49:23 -07:00
parent 1589e41b8b
commit a8b66666f5
2 changed files with 7 additions and 1 deletions

View File

@ -725,6 +725,12 @@ func MergeConfig(a, b *Config) *Config {
if b.DisableRemoteExec {
result.DisableRemoteExec = true
}
if b.DisableUpdateCheck {
result.DisableUpdateCheck = true
}
if b.DisableAnonymousSignature {
result.DisableAnonymousSignature = true
}
// Copy the start join addresses
result.StartJoin = make([]string, 0, len(a.StartJoin)+len(b.StartJoin))

View File

@ -122,7 +122,7 @@ func TestIngestUserEvent(t *testing.T) {
defer agent.Shutdown()
for i := 0; i < 512; i++ {
msg := &UserEvent{LTime: uint64(i)}
msg := &UserEvent{LTime: uint64(i), Name: "test"}
agent.ingestUserEvent(msg)
if agent.LastUserEvent() != msg {
t.Fatalf("bad: %#v", msg)