equal
deleted
inserted
replaced
31 #include <string.h> |
31 #include <string.h> |
32 #include <poll.h> |
32 #include <poll.h> |
33 |
33 |
34 #if __linux__ |
34 #if __linux__ |
35 #include <netinet/in.h> |
35 #include <netinet/in.h> |
36 #endif |
|
37 |
|
38 #if defined(__solaris__) && !defined(_SOCKLEN_T) |
|
39 typedef size_t socklen_t; /* New in SunOS 5.7, so need this for 5.6 */ |
|
40 #endif |
36 #endif |
41 |
37 |
42 #include "jni.h" |
38 #include "jni.h" |
43 #include "jni_util.h" |
39 #include "jni_util.h" |
44 #include "net_util.h" |
40 #include "net_util.h" |
86 } |
82 } |
87 return 1; |
83 return 1; |
88 } |
84 } |
89 return 0; |
85 return 0; |
90 } |
86 } |
91 |
|
92 |
|
93 JNIEXPORT void JNICALL |
|
94 Java_sun_nio_ch_SocketChannelImpl_shutdown(JNIEnv *env, jclass cl, |
|
95 jobject fdo, jint how) |
|
96 { |
|
97 if (shutdown(fdval(env, fdo), how) < 0) |
|
98 handleSocketError(env, errno); |
|
99 } |
|