File tree Expand file tree Collapse file tree 1 file changed +2
-19
lines changed Expand file tree Collapse file tree 1 file changed +2
-19
lines changed Original file line number Diff line number Diff line change @@ -77,24 +77,6 @@ func (s *success) isResetResponse() bool {
77
77
return s .num == 0
78
78
}
79
79
80
- // Since it is reused
81
- func (s * success ) clear () {
82
- s .fields = nil
83
- s .bookmark = ""
84
- s .hasMore = false
85
- s .notifications = nil
86
- s .plan = nil
87
- s .profile = nil
88
- s .qid = - 1
89
- s .server = ""
90
- s .connectionId = ""
91
- s .server = ""
92
- s .tfirst = 0
93
- s .tlast = 0
94
- s .db = ""
95
- s .qtype = db .StatementTypeUnknown
96
- }
97
-
98
80
type hydrator struct {
99
81
unpacker packstream.Unpacker
100
82
unp * packstream.Unpacker
@@ -189,8 +171,9 @@ func (h *hydrator) success(n uint32) *success {
189
171
return nil
190
172
}
191
173
// Use cached success but clear it first
174
+ h .cachedSuccess = success {}
175
+ h .cachedSuccess .qid = - 1
192
176
succ := & h .cachedSuccess
193
- succ .clear ()
194
177
195
178
h .unp .Next () // Detect map
196
179
n = h .unp .Len ()
You can’t perform that action at this time.
0 commit comments