fix pointer dereference in memory registry

Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
This commit is contained in:
Василий Толстов 2019-12-03 18:47:11 +03:00
parent 81a7cf458c
commit 7d5bdcf993

View File

@ -44,9 +44,9 @@ func recordToService(r *record) *registry.Service {
endpoints := make([]*registry.Endpoint, len(r.Endpoints))
for i, e := range r.Endpoints {
request := new(registry.Value)
request = e.Request
*request = *e.Request
response := new(registry.Value)
response = e.Response
*response = *e.Response
metadata := make(map[string]string)
for k, v := range e.Metadata {