mirror of
https://github.com/ceph/ceph-csi.git
synced 2025-06-13 10:33:35 +00:00
rebase: update go-ceph to v0.8.0
Updating go-ceph to v0.8.0. Signed-off-by: Mudit Agarwal <muagarwa@redhat.com>
This commit is contained in:
committed by
mergify[bot]
parent
e6098520d1
commit
32d78c4f7f
33
vendor/github.com/ceph/go-ceph/rados/write_step.go
generated
vendored
Normal file
33
vendor/github.com/ceph/go-ceph/rados/write_step.go
generated
vendored
Normal file
@ -0,0 +1,33 @@
|
||||
package rados
|
||||
|
||||
// #include <stdint.h>
|
||||
import "C"
|
||||
|
||||
import (
|
||||
"unsafe"
|
||||
)
|
||||
|
||||
type writeStep struct {
|
||||
withoutUpdate
|
||||
withoutFree
|
||||
// the c pointer utilizes the Go byteslice data and no free is needed
|
||||
|
||||
// inputs:
|
||||
b []byte
|
||||
|
||||
// arguments:
|
||||
cBuffer *C.char
|
||||
cDataLen C.size_t
|
||||
cWriteLen C.size_t
|
||||
cOffset C.uint64_t
|
||||
}
|
||||
|
||||
func newWriteStep(b []byte, writeLen, offset uint64) *writeStep {
|
||||
return &writeStep{
|
||||
b: b,
|
||||
cBuffer: (*C.char)(unsafe.Pointer(&b[0])),
|
||||
cDataLen: C.size_t(len(b)),
|
||||
cWriteLen: C.size_t(writeLen),
|
||||
cOffset: C.uint64_t(offset),
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user