Skip to content

Commit

Permalink
fix panic in span reporting
Browse files Browse the repository at this point in the history
  • Loading branch information
qrort committed Jan 7, 2025
1 parent 4068af9 commit 6a58bc9
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 0 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
## v3.95.6
* Fixed panic on span reporting in `xsql/Tx`

## v3.95.5
* Fixed goroutine leak on failed execute call in query client

Expand Down
4 changes: 4 additions & 0 deletions internal/xsql/legacy/tx.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,10 @@ type transaction struct {
}

func (tx *transaction) ID() string {
if tx.tx == nil {
return ""
}

return tx.tx.ID()
}

Expand Down
4 changes: 4 additions & 0 deletions internal/xsql/tx.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,10 @@ type Tx struct {
}

func (tx *Tx) ID() string {
if tx.tx == nil {
return ""
}

return tx.tx.ID()
}

Expand Down

0 comments on commit 6a58bc9

Please sign in to comment.