mirror of
https://github.com/protocolbuffers/protobuf-go.git
synced 2025-04-10 15:44:42 +00:00
Under some rare circumstances registration can deadlock when lazy descriptor initialization consults the registry. Move the call triggering the lazy init out of the critical section. Fixes golang/protobuf#1052. Change-Id: Ic266e06b0db99fea65e797b879ce53e5342fff95 Reviewed-on: https://go-review.googlesource.com/c/protobuf/+/204804 Reviewed-by: Joe Tsai <thebrokentoaster@gmail.com>
10 lines
260 B
Go
10 lines
260 B
Go
// Copyright 2020 The Go Authors. All rights reserved.
|
|
// Use of this source code is governed by a BSD-style
|
|
// license that can be found in the LICENSE file.
|
|
|
|
package bug1052_test
|
|
|
|
import (
|
|
_ "google.golang.org/protobuf/internal/testprotos/legacy/bug1052"
|
|
)
|