summaryrefslogtreecommitdiffstats
path: root/vendor/github.com/golang/protobuf
diff options
context:
space:
mode:
authorWim <wim@42.be>2021-06-16 21:00:49 +0200
committerGitHub <noreply@github.com>2021-06-16 21:00:49 +0200
commitfb5a84212c491332504fcdd4b5f4a4b97705d2e3 (patch)
treebe03e973d30d040a49a90c47f1e6b73ed8922539 /vendor/github.com/golang/protobuf
parentdedc1c45a113d8db373d9e4638f54a0f9d29624f (diff)
downloadmatterbridge-msglm-fb5a84212c491332504fcdd4b5f4a4b97705d2e3.tar.gz
matterbridge-msglm-fb5a84212c491332504fcdd4b5f4a4b97705d2e3.tar.bz2
matterbridge-msglm-fb5a84212c491332504fcdd4b5f4a4b97705d2e3.zip
Update dependencies (#1521)
Diffstat (limited to 'vendor/github.com/golang/protobuf')
-rw-r--r--vendor/github.com/golang/protobuf/proto/registry.go10
-rw-r--r--vendor/github.com/golang/protobuf/proto/text_decode.go2
2 files changed, 3 insertions, 9 deletions
diff --git a/vendor/github.com/golang/protobuf/proto/registry.go b/vendor/github.com/golang/protobuf/proto/registry.go
index 1e7ff642..066b4323 100644
--- a/vendor/github.com/golang/protobuf/proto/registry.go
+++ b/vendor/github.com/golang/protobuf/proto/registry.go
@@ -13,6 +13,7 @@ import (
"strings"
"sync"
+ "google.golang.org/protobuf/reflect/protodesc"
"google.golang.org/protobuf/reflect/protoreflect"
"google.golang.org/protobuf/reflect/protoregistry"
"google.golang.org/protobuf/runtime/protoimpl"
@@ -62,14 +63,7 @@ func FileDescriptor(s filePath) fileDescGZIP {
// Find the descriptor in the v2 registry.
var b []byte
if fd, _ := protoregistry.GlobalFiles.FindFileByPath(s); fd != nil {
- if fd, ok := fd.(interface{ ProtoLegacyRawDesc() []byte }); ok {
- b = fd.ProtoLegacyRawDesc()
- } else {
- // TODO: Use protodesc.ToFileDescriptorProto to construct
- // a descriptorpb.FileDescriptorProto and marshal it.
- // However, doing so causes the proto package to have a dependency
- // on descriptorpb, leading to cyclic dependency issues.
- }
+ b, _ = Marshal(protodesc.ToFileDescriptorProto(fd))
}
// Locally cache the raw descriptor form for the file.
diff --git a/vendor/github.com/golang/protobuf/proto/text_decode.go b/vendor/github.com/golang/protobuf/proto/text_decode.go
index 4a593100..47eb3e44 100644
--- a/vendor/github.com/golang/protobuf/proto/text_decode.go
+++ b/vendor/github.com/golang/protobuf/proto/text_decode.go
@@ -765,7 +765,7 @@ func unescape(s string) (ch string, tail string, err error) {
if i > utf8.MaxRune {
return "", "", fmt.Errorf(`\%c%s is not a valid Unicode code point`, r, ss)
}
- return string(i), s, nil
+ return string(rune(i)), s, nil
}
return "", "", fmt.Errorf(`unknown escape \%c`, r)
}