linux-nfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] xdr_rejected_reply: Don't crash with invalid server rejection
@ 2014-06-05 13:48 Steve Dickson
  2014-06-18 20:44 ` [Libtirpc-devel] " Steve Dickson
  0 siblings, 1 reply; 2+ messages in thread
From: Steve Dickson @ 2014-06-05 13:48 UTC (permalink / raw)
  To: Libtirpc-devel Mailing List; +Cc: Linux NFS Mailing list

It seems legacy servers like to return invalid
rejection status when a RPC is rejected. This
should not crash the app then it happens.

Signed-off-by: Steve Dickson <steved@redhat.com>
---
 src/rpc_prot.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/src/rpc_prot.c b/src/rpc_prot.c
index e562deb..5841e51 100644
--- a/src/rpc_prot.c
+++ b/src/rpc_prot.c
@@ -150,7 +150,6 @@ xdr_rejected_reply(xdrs, rr)
 		return (xdr_enum(xdrs, (enum_t *)&(rr->rj_why)));
 	}
 	/* NOTREACHED */
-	assert(0);
 	return (FALSE);
 }
 
-- 
1.9.0


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [Libtirpc-devel] [PATCH] xdr_rejected_reply: Don't crash with invalid server rejection
  2014-06-05 13:48 [PATCH] xdr_rejected_reply: Don't crash with invalid server rejection Steve Dickson
@ 2014-06-18 20:44 ` Steve Dickson
  0 siblings, 0 replies; 2+ messages in thread
From: Steve Dickson @ 2014-06-18 20:44 UTC (permalink / raw)
  To: Libtirpc-devel Mailing List; +Cc: Linux NFS Mailing list



On 06/05/2014 09:48 AM, Steve Dickson wrote:
> It seems legacy servers like to return invalid
> rejection status when a RPC is rejected. This
> should not crash the app then it happens.
> 
> Signed-off-by: Steve Dickson <steved@redhat.com>
Committed.... 

steved.

> ---
>  src/rpc_prot.c | 1 -
>  1 file changed, 1 deletion(-)
> 
> diff --git a/src/rpc_prot.c b/src/rpc_prot.c
> index e562deb..5841e51 100644
> --- a/src/rpc_prot.c
> +++ b/src/rpc_prot.c
> @@ -150,7 +150,6 @@ xdr_rejected_reply(xdrs, rr)
>  		return (xdr_enum(xdrs, (enum_t *)&(rr->rj_why)));
>  	}
>  	/* NOTREACHED */
> -	assert(0);
>  	return (FALSE);
>  }
>  
> 

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2014-06-18 20:45 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-06-05 13:48 [PATCH] xdr_rejected_reply: Don't crash with invalid server rejection Steve Dickson
2014-06-18 20:44 ` [Libtirpc-devel] " Steve Dickson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).