Skip to content

Commit 023805a

Browse files
committed
Changed Message.Opaque to non-pointer interface{} (issue confluentinc#4)
1 parent 882f4b1 commit 023805a

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

kafka/handle.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,7 @@ type cgoif interface{}
169169
// delivery report cgoif container
170170
type cgo_dr struct {
171171
delivery_chan chan Event
172-
opaque *interface{}
172+
opaque interface{}
173173
}
174174

175175
// cgo_put adds object cg to the handle's cgo map and returns a

kafka/message.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ type Message struct {
9292
Key []byte
9393
Timestamp time.Time
9494
TimestampType TimestampType
95-
Opaque *interface{}
95+
Opaque interface{}
9696
}
9797

9898
// String returns a human readable representation of a Message.

kafka/producer.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ func (p *Producer) get_handle() *handle {
6161
// transmit queue, thus returning immediately.
6262
// The delivery report will be sent on the provided delivery_chan if specified,
6363
// or on the Producer object's Events channel if not.
64-
func (p *Producer) produce(msg *Message, msg_flags int, delivery_chan chan Event, opaque *interface{}) error {
64+
func (p *Producer) produce(msg *Message, msg_flags int, delivery_chan chan Event, opaque interface{}) error {
6565
c_rkt := p.handle.get_rkt(*msg.TopicPartition.Topic)
6666

6767
var valp *byte = nil
@@ -115,7 +115,7 @@ func (p *Producer) produce(msg *Message, msg_flags int, delivery_chan chan Event
115115
return nil
116116
}
117117

118-
func (p *Producer) Produce(msg *Message, delivery_chan chan Event, opaque *interface{}) error {
118+
func (p *Producer) Produce(msg *Message, delivery_chan chan Event, opaque interface{}) error {
119119
return p.produce(msg, 0, delivery_chan, opaque)
120120
}
121121

0 commit comments

Comments
 (0)