File tree Expand file tree Collapse file tree 2 files changed +13
-10
lines changed
Expand file tree Collapse file tree 2 files changed +13
-10
lines changed Original file line number Diff line number Diff line change @@ -9,4 +9,6 @@ pom.xml.asc
99/.nrepl-port
1010.DS_Store
1111/doc
12- push
12+ push
13+ * .iml
14+ .idea /
Original file line number Diff line number Diff line change 174174 (with-buffer [buf slab]
175175 (reset! status s)
176176 (.put buf (p/+ offset 1 )
177- (case s
178- :incomplete 0
179- :in-progress 1
180- :complete 2 ))
177+ (byte
178+ (case s
179+ :incomplete 0
180+ :in-progress 1
181+ :complete 2 )))
181182 (invalidate slab (p/+ offset 1 ) 1 )
182183 nil )))
183184
190191 (fn []
191192 (with-buffer [buf slab]
192193 (let [^ByteBuffer buf (-> buf
193- (.position offset)
194+ (.position ^Long offset)
194195 ^ByteBuffer
195- (.limit (+ offset len))
196+ (.limit ^Long (+ offset len))
196197 .slice)
197198 checksum' (.getLong buf 2 )
198199 ary (bs/to-byte-array (.position buf header-size))]
303304 (let [ary (nippy/freeze descriptor)
304305 cnt (count ary)
305306 pos @position
306- ^ByteBuffer buf (.position buf pos)]
307+ ^ByteBuffer buf (.position buf ^Long pos)]
307308
308309 (when (> (.remaining buf) (+ (count ary) header-size))
309310 ; ; write to the buffer
310311 (doto buf
311- (.position pos)
312+ (.position ^Long pos)
312313 (.put (byte 1 )) ; ; exists
313314 (.put (byte 0 )) ; ; incomplete
314315 (.putLong (checksum cnt ary))
315316 (.putInt cnt)
316- (.put ary)
317+ (.put ^bytes ary)
317318 (.put (byte 0 ))) ; ; next doesn't exist
318319
319320 (swap! position + header-size cnt)
You can’t perform that action at this time.
0 commit comments