All of lore.kernel.org
 help / color / mirror / Atom feed
diff for duplicates of <537EA6D8.5050604@gmail.com>

diff --git a/a/1.txt b/N1/1.txt
index cc718b3..c33a3cf 100644
--- a/a/1.txt
+++ b/N1/1.txt
@@ -111,7 +111,7 @@ member of the union to use.
 >  	}
 >  
 > -	sinfo = cmsgs.info;
-> +	if(cmsgs.cmsg_type = SCTP_SNDINFO){
+> +	if(cmsgs.cmsg_type == SCTP_SNDINFO){
 > +		sndinfo = (struct sctp_sndinfo*) cmsgs.info;
 > +		memset(&default_sinfo, 0, sizeof(default_sinfo));
 > +		default_sinfo.sinfo_flags = sndinfo->snd_flags;
@@ -255,7 +255,7 @@ You also appear to be leaking the nxtskb.
 > +	if(get_user(val, (int __user*)optval)){
 > +		return -EFAULT;
 > +	}
-> +	sctp_sk(sk)->recvrcvinfo = (val = 0) ? 0 : 1;
+> +	sctp_sk(sk)->recvrcvinfo = (val == 0) ? 0 : 1;
 > +	return 0;
 > +}
 > +static int sctp_setsockopt_recvnxtinfo(struct sock *sk,
@@ -269,7 +269,7 @@ You also appear to be leaking the nxtskb.
 > +	if(get_user(val, (int __user*)optval)){
 > +		return -EFAULT;
 > +	}
-> +	sctp_sk(sk)->recvnxtinfo = (val = 0) ? 0 : 1;
+> +	sctp_sk(sk)->recvnxtinfo = (val == 0) ? 0 : 1;
 > +	return 0;
 > +}
 > +
@@ -381,7 +381,7 @@ You also appear to be leaking the nxtskb.
 > +		return -EINVAL;
 > +
 > +	len = sizeof(int);
-> +	val = (sctp_sk(sk)->recvrcvinfo = 1);
+> +	val = (sctp_sk(sk)->recvrcvinfo == 1);
 > +	if (put_user(len, optlen))
 > +		return -EFAULT;
 > +	if (copy_to_user(optval, &val, len))
@@ -399,7 +399,7 @@ You also appear to be leaking the nxtskb.
 > +		return -EINVAL;
 > +
 > +	len = sizeof(int);
-> +	val = (sctp_sk(sk)->recvnxtinfo = 1);
+> +	val = (sctp_sk(sk)->recvnxtinfo == 1);
 > +
 > +	if(put_user(len, optlen))
 > +		return -EFAULT;
@@ -438,13 +438,15 @@ You also appear to be leaking the nxtskb.
 > @@ -6416,17 +6627,52 @@ static int sctp_msghdr_parse(const struc
 >  			 * IPPROTO_SCTP  SCTP_SNDRCV    struct sctp_sndrcvinfo
 >  			 */
->  			if (cmsg->cmsg_len !> -			    CMSG_LEN(sizeof(struct sctp_sndrcvinfo)))
+>  			if (cmsg->cmsg_len !=
+> -			    CMSG_LEN(sizeof(struct sctp_sndrcvinfo)))
 > +			    CMSG_LEN(sizeof(struct sctp_sndrcvinfo))){
 > +
 >  				return -EINVAL;
 > +			}
 >  
->  			cmsgs->info >  				(struct sctp_sndrcvinfo *)CMSG_DATA(cmsg);
+>  			cmsgs->info =
+>  				(struct sctp_sndrcvinfo *)CMSG_DATA(cmsg);
 > +			cmsgs->cmsg_type = SCTP_SNDRCV;
 >  
 >  			/* Minimally, validate the sinfo_flags. */
diff --git a/a/content_digest b/N1/content_digest
index e65bd9a..7760d80 100644
--- a/a/content_digest
+++ b/N1/content_digest
@@ -1,7 +1,7 @@
  "ref\0CAB7CvPO0y4jCYagHVkbL3-g4iq22WLpsucBjou30ruPtWFvUHw@mail.gmail.com\0"
  "From\0Vlad Yasevich <vyasevich@gmail.com>\0"
  "Subject\0Re: [PATCH lksctp-tools] A few things that should get the API closer to RFC6458 compliancy\0"
- "Date\0Fri, 23 May 2014 01:39:36 +0000\0"
+ "Date\0Thu, 22 May 2014 21:39:36 -0400\0"
  "To\0Geir Ola Vaagland <geirola@gmail.com>"
   linux-sctp@vger.kernel.org
  " netdev@vger.kernel.org\0"
@@ -120,7 +120,7 @@
  ">  \t}\n"
  ">  \n"
  "> -\tsinfo = cmsgs.info;\n"
- "> +\tif(cmsgs.cmsg_type = SCTP_SNDINFO){\n"
+ "> +\tif(cmsgs.cmsg_type == SCTP_SNDINFO){\n"
  "> +\t\tsndinfo = (struct sctp_sndinfo*) cmsgs.info;\n"
  "> +\t\tmemset(&default_sinfo, 0, sizeof(default_sinfo));\n"
  "> +\t\tdefault_sinfo.sinfo_flags = sndinfo->snd_flags;\n"
@@ -264,7 +264,7 @@
  "> +\tif(get_user(val, (int __user*)optval)){\n"
  "> +\t\treturn -EFAULT;\n"
  "> +\t}\n"
- "> +\tsctp_sk(sk)->recvrcvinfo = (val = 0) ? 0 : 1;\n"
+ "> +\tsctp_sk(sk)->recvrcvinfo = (val == 0) ? 0 : 1;\n"
  "> +\treturn 0;\n"
  "> +}\n"
  "> +static int sctp_setsockopt_recvnxtinfo(struct sock *sk,\n"
@@ -278,7 +278,7 @@
  "> +\tif(get_user(val, (int __user*)optval)){\n"
  "> +\t\treturn -EFAULT;\n"
  "> +\t}\n"
- "> +\tsctp_sk(sk)->recvnxtinfo = (val = 0) ? 0 : 1;\n"
+ "> +\tsctp_sk(sk)->recvnxtinfo = (val == 0) ? 0 : 1;\n"
  "> +\treturn 0;\n"
  "> +}\n"
  "> +\n"
@@ -390,7 +390,7 @@
  "> +\t\treturn -EINVAL;\n"
  "> +\n"
  "> +\tlen = sizeof(int);\n"
- "> +\tval = (sctp_sk(sk)->recvrcvinfo = 1);\n"
+ "> +\tval = (sctp_sk(sk)->recvrcvinfo == 1);\n"
  "> +\tif (put_user(len, optlen))\n"
  "> +\t\treturn -EFAULT;\n"
  "> +\tif (copy_to_user(optval, &val, len))\n"
@@ -408,7 +408,7 @@
  "> +\t\treturn -EINVAL;\n"
  "> +\n"
  "> +\tlen = sizeof(int);\n"
- "> +\tval = (sctp_sk(sk)->recvnxtinfo = 1);\n"
+ "> +\tval = (sctp_sk(sk)->recvnxtinfo == 1);\n"
  "> +\n"
  "> +\tif(put_user(len, optlen))\n"
  "> +\t\treturn -EFAULT;\n"
@@ -447,13 +447,15 @@
  "> @@ -6416,17 +6627,52 @@ static int sctp_msghdr_parse(const struc\n"
  ">  \t\t\t * IPPROTO_SCTP  SCTP_SNDRCV    struct sctp_sndrcvinfo\n"
  ">  \t\t\t */\n"
- ">  \t\t\tif (cmsg->cmsg_len !> -\t\t\t    CMSG_LEN(sizeof(struct sctp_sndrcvinfo)))\n"
+ ">  \t\t\tif (cmsg->cmsg_len !=\n"
+ "> -\t\t\t    CMSG_LEN(sizeof(struct sctp_sndrcvinfo)))\n"
  "> +\t\t\t    CMSG_LEN(sizeof(struct sctp_sndrcvinfo))){\n"
  "> +\n"
  ">  \t\t\t\treturn -EINVAL;\n"
  "> +\t\t\t}\n"
  ">  \n"
- ">  \t\t\tcmsgs->info >  \t\t\t\t(struct sctp_sndrcvinfo *)CMSG_DATA(cmsg);\n"
+ ">  \t\t\tcmsgs->info =\n"
+ ">  \t\t\t\t(struct sctp_sndrcvinfo *)CMSG_DATA(cmsg);\n"
  "> +\t\t\tcmsgs->cmsg_type = SCTP_SNDRCV;\n"
  ">  \n"
  ">  \t\t\t/* Minimally, validate the sinfo_flags. */\n"
@@ -1137,4 +1139,4 @@
  "> +\n"
  >
 
-c6e8d2d4bafe9ae1583bf3b39e96fb96eef721386e470ad637b83946663cb80a
+5c746be5fb4b81fd669a99d4249c62a67f1b7f86dce5c62723c00134f0cf6914

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.