summaryrefslogtreecommitdiff
path: root/src/xdr_rec.c
Commit message (Collapse)AuthorAgeFilesLines
* Fix EOF detection on non-blocking socketlibtirpc-1-1-5-rc2Ian Kent2018-11-081-2/+16
| | | | | | | | | | | | | | | | | | | | | From: Ian Kent <raven@themaw.net> EOF on a non-blocking socket is incorrectly detected causing the socket to be closed if a client sends the RPC request in more than one write. This is becuase ->read_vc() returns 0 for a real EOF and for the error cases of EAGAIN or EWOULDBLOCK when there could be more data to come. The caller of ->read_vc() also fails to handle this case correctly returning XPRT_DIED in both cases. Also the stream context setting that indicates the request header has been reveived is not set after receiving the header which causes incorrect interpretation of the input for the case of a multiple read receive. Signed-off-by: Ian Kent <raven@themaw.net> Signed-off-by: Steve Dickson <steved@redhat.com>
* Avoid use of internal glibc sys/cdefs.h headerNatanael Copa2015-04-231-2/+0
| | | | | | | | | | | | This header was never intended to be used by programs. Expand the macros used, __BEGIN_CDECLS, __END_CDECLS and __P() The __THROW macro is a non-portable hint for optimization so we simply remove those. Signed-off-by: Natanael Copa <ncopa@alpinelinux.org> Signed-off-by: Steve Dickson <steved@redhat.com>
* Use of lseek() in xdr_rec.c:xdrrec_getpos().Matthew N. Dodd2011-06-211-14/+13
| | | | | | | | | | | | | | | | The use of lseek() in xdr_rec.c:xdrrec_getpos() without checking for ESPIPE will fail to handle the common case, resulting in poor behavior in calling code. (In particular auth_gss.c:authgss_marshal() calls gss_get_mic() with rpcbuf.length set to -1, with spectacular results.) The original MIT Krb5 RPC code lacks this addition, which I'm unclear of the utility of in the first place. Reverting to the MIT code permits correct function of a trivial RPC client using GSS. Signed-off-by: Frank Filz <ffilzlnx@us.ibm.com> Signed-off-by: Steve Dickson <steved@redhat.com>
* Replace the Sun RPC license with the BSD license, with the explicitTom "spot" Callaway2009-05-281-24/+23
| | | | | | | permission of Sun Microsystems Signed-off-by: Tom "spot" Callaway <tcallawa@redhat.com> Signed-off-by: Steve Dickson <steved@redhat.com>
* Initial commit of libtirpc 0.1.7Steve Dickson2007-04-201-0/+782
Signed-off-by: Steve Dickson <steved@redhat.com>