natPlainSocketImpl.cc (_Jv_recv): Change return type of function and of parameter recv_func to ssize_t...
* java/net/natPlainSocketImpl.cc (_Jv_recv): Change return type of function and of parameter recv_func to ssize_t, as specified by POSIX. From-SVN: r49020
This commit is contained in:
parent
6b6996b803
commit
464115ce93
2 changed files with 8 additions and 2 deletions
|
@ -72,8 +72,8 @@ _Jv_accept (int fd, struct sockaddr *addr, socklen_t *addrlen)
|
|||
|
||||
// A wrapper for recv so we don't have to do configure tests.
|
||||
template <typename T_fd, typename T_buf, typename T_len, typename T_flags>
|
||||
static inline int
|
||||
_Jv_recv (int (*recv_func) (T_fd s, T_buf buf, T_len len, T_flags flags),
|
||||
static inline ssize_t
|
||||
_Jv_recv (ssize_t (*recv_func) (T_fd s, T_buf buf, T_len len, T_flags flags),
|
||||
int s, void *buf, size_t len, int flags)
|
||||
{
|
||||
return recv_func ((T_fd) s, (T_buf) buf, (T_len) len, (T_flags) flags);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue