Skip to content

Commit 72cf960

Browse files
gzlicanyirobertroeser
authored andcommitted
polishing (rsocket#662)
* Polishing Signed-off-by: gzlicanyi <gzlicanyi@163.com> * Polishing Signed-off-by: gzlicanyi <gzlicanyi@163.com>
1 parent 42eadde commit 72cf960

2 files changed

Lines changed: 6 additions & 3 deletions

File tree

rsocket-core/src/main/java/io/rsocket/fragmentation/FrameReassembler.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,9 @@
3838
* and Reassembly</a>
3939
*/
4040
final class FrameReassembler extends AtomicBoolean implements Disposable {
41+
42+
private static final long serialVersionUID = -4394598098863449055L;
43+
4144
private static final Logger logger = LoggerFactory.getLogger(FrameReassembler.class);
4245

4346
final IntObjectMap<ByteBuf> headers;

rsocket-core/src/main/java/io/rsocket/internal/SynchronizedIntObjectHashMap.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -189,7 +189,7 @@ public synchronized boolean isEmpty() {
189189

190190
@Override
191191
public synchronized void clear() {
192-
Arrays.fill(keys, (int) 0);
192+
Arrays.fill(keys, 0);
193193
Arrays.fill(values, null);
194194
size = 0;
195195
}
@@ -331,7 +331,7 @@ public synchronized Set<Entry<Integer, V>> entrySet() {
331331
}
332332

333333
private int objectToKey(Object key) {
334-
return (int) ((Integer) key).intValue();
334+
return ((Integer) key).intValue();
335335
}
336336

337337
/**
@@ -369,7 +369,7 @@ private int hashIndex(int key) {
369369

370370
/** Returns the hash code for the key. */
371371
private static int hashCode(int key) {
372-
return (int) key;
372+
return key;
373373
}
374374

375375
/** Get the next sequential index after {@code index} and wraps if necessary. */

0 commit comments

Comments
 (0)