Skip to content

Commit

Permalink
WIP
Browse files Browse the repository at this point in the history
  • Loading branch information
ansiwen committed Sep 21, 2023
1 parent c0d4e61 commit e3d729c
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions rados/rados.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,6 @@ import "C"
import (
"runtime"
"unsafe"

"github.com/ceph/go-ceph/internal/log"
)

const (
Expand Down Expand Up @@ -122,9 +120,9 @@ func NewConnWithClusterAndUser(clusterName string, userName string) (*Conn, erro
// called.
func freeConn(conn *Conn) {
if conn.cluster != nil {
log.Warnf("unreachable Conn object has not been shut down. Cleaning up.")
C.rados_shutdown(conn.cluster)
// prevent calling rados_shutdown() more than once
conn.cluster = nil
panic("unreachable Conn object has not been shut down.")
// C.rados_shutdown(conn.cluster)
// // prevent calling rados_shutdown() more than once
// conn.cluster = nil
}
}

0 comments on commit e3d729c

Please sign in to comment.