Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
JAliEn
JAliEn
Commits
b941a19d
Commit
b941a19d
authored
May 05, 2021
by
Costin Grigoras
Browse files
Clean up unused parts
parent
8273043a
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/main/java/alien/api/DispatchSSLServerNIO.java
View file @
b941a19d
...
@@ -10,7 +10,6 @@ import java.io.PipedOutputStream;
...
@@ -10,7 +10,6 @@ import java.io.PipedOutputStream;
import
java.net.Inet6Address
;
import
java.net.Inet6Address
;
import
java.net.InetSocketAddress
;
import
java.net.InetSocketAddress
;
import
java.nio.ByteBuffer
;
import
java.nio.ByteBuffer
;
import
java.nio.channels.ClosedChannelException
;
import
java.nio.channels.SelectionKey
;
import
java.nio.channels.SelectionKey
;
import
java.nio.channels.Selector
;
import
java.nio.channels.Selector
;
import
java.nio.channels.ServerSocketChannel
;
import
java.nio.channels.ServerSocketChannel
;
...
@@ -256,7 +255,7 @@ public class DispatchSSLServerNIO implements Runnable {
...
@@ -256,7 +255,7 @@ public class DispatchSSLServerNIO implements Runnable {
return
remoteIdentity
!=
null
;
return
remoteIdentity
!=
null
;
}
}
private
void
notifyData
()
throws
IOException
{
private
void
notifyData
()
{
// System.err.println("Handling data notification");
// System.err.println("Handling data notification");
if
(
isKilled
.
get
())
if
(
isKilled
.
get
())
...
@@ -532,14 +531,14 @@ public class DispatchSSLServerNIO implements Runnable {
...
@@ -532,14 +531,14 @@ public class DispatchSSLServerNIO implements Runnable {
if
(
key
==
null
||
!
key
.
isValid
())
{
if
(
key
==
null
||
!
key
.
isValid
())
{
logger
.
log
(
Level
.
INFO
,
"Detected closed key, disposing of it"
);
logger
.
log
(
Level
.
INFO
,
"Detected closed key, disposing of it"
);
if
(
key
!=
null
){
if
(
key
!=
null
)
{
final
DispatchSSLServerNIO
obj
=
sessionMap
.
remove
(
key
);
final
DispatchSSLServerNIO
obj
=
sessionMap
.
remove
(
key
);
if
(
obj
!=
null
){
if
(
obj
!=
null
)
{
try
{
try
{
obj
.
cleanup
();
obj
.
cleanup
();
}
}
catch
(
final
Throwable
t
){
catch
(
final
Throwable
t
)
{
logger
.
log
(
Level
.
WARNING
,
"Cleaning up an invalid key encountered a problem"
,
t
);
logger
.
log
(
Level
.
WARNING
,
"Cleaning up an invalid key encountered a problem"
,
t
);
}
}
}
}
...
@@ -561,12 +560,12 @@ public class DispatchSSLServerNIO implements Runnable {
...
@@ -561,12 +560,12 @@ public class DispatchSSLServerNIO implements Runnable {
try
{
try
{
obj
.
notifyData
();
obj
.
notifyData
();
}
}
catch
(
final
Throwable
t1
){
catch
(
final
Throwable
t1
)
{
try
{
try
{
logger
.
log
(
Level
.
WARNING
,
"Throwable notifying data"
,
t1
);
logger
.
log
(
Level
.
WARNING
,
"Throwable notifying data"
,
t1
);
obj
.
cleanup
();
obj
.
cleanup
();
}
}
catch
(
final
Throwable
t
){
catch
(
final
Throwable
t
)
{
logger
.
log
(
Level
.
WARNING
,
"Cleaning up after an error encountered a problem"
,
t
);
logger
.
log
(
Level
.
WARNING
,
"Cleaning up after an error encountered a problem"
,
t
);
}
}
}
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment