diff for duplicates of <4C5ECAA4.9050606@bfs.de> diff --git a/a/1.txt b/N1/1.txt index c1f741c..d657c9f 100644 --- a/a/1.txt +++ b/N1/1.txt @@ -19,13 +19,13 @@ Roberto Rodriguez Alkala schrieb: > /* Find retryRate in operationRateSet[] */ > - for (i=0; i<rcCell->operationRateCount; i++) > - { -> - if (retryRate = rcCell->operationRateSet[i]) +> - if (retryRate == rcCell->operationRateSet[i]) > - { > - if (i < rcCell->currentRateIndex) > - { > - return ((rcCell->currentRateIndex - i)+1)>>1; > - } -> - else if (i = rcCell->currentRateIndex = 0) +> - else if (i == rcCell->currentRateIndex == 0) > - { > - return 1; > - } @@ -35,10 +35,10 @@ Roberto Rodriguez Alkala schrieb: > - } > - } > + for (i = 0; i < rcCell->operationRateCount; i++) { -> + if (retryRate = rcCell->operationRateSet[i]) { +> + if (retryRate == rcCell->operationRateSet[i]) { > + if (i < rcCell->currentRateIndex) > + return ((rcCell->currentRateIndex - i)+1)>>1; -> + else if (i = rcCell->currentRateIndex && i = 0) +> + else if (i == rcCell->currentRateIndex && i == 0) > + return 1; > + else > + return 0; @@ -52,7 +52,7 @@ mmh, it is a matter of taste but to improve readablity i would make the special case i=0 first and let the loop start with i=1. /* untested code below, assuming rcCell->currentRateIndex>=0 */ - if ( retryRate = rcCell->operationRateSet[0] && rcCell->currentRateIndex= 0 ) + if ( retryRate == rcCell->operationRateSet[0] && rcCell->currentRateIndex== 0 ) return 1; for (i = 1; i < rcCell->operationRateCount; i++) { diff --git a/a/content_digest b/N1/content_digest index 01f0ddc..6ae3167 100644 --- a/a/content_digest +++ b/N1/content_digest @@ -1,7 +1,7 @@ "ref\01281225149.10826.5.camel@lenovo\0" "From\0walter harms <wharms@bfs.de>\0" "Subject\0Re: [PATCH] stating: otus: fix compile warning and some style issues\0" - "Date\0Sun, 08 Aug 2010 15:17:56 +0000\0" + "Date\0Sun, 08 Aug 2010 17:17:56 +0200\0" "To\0Roberto Rodriguez Alkala <rralcala@gmail.com>\0" "Cc\0Greg Kroah-Hartman <gregkh@suse.de>" Joe Perches <joe@perches.com> @@ -31,13 +31,13 @@ "> /* Find retryRate in operationRateSet[] */\n" "> - for (i=0; i<rcCell->operationRateCount; i++)\n" "> - {\n" - "> - if (retryRate = rcCell->operationRateSet[i])\n" + "> - if (retryRate == rcCell->operationRateSet[i])\n" "> - {\n" "> - if (i < rcCell->currentRateIndex)\n" "> - {\n" "> - return ((rcCell->currentRateIndex - i)+1)>>1;\n" "> - }\n" - "> - else if (i = rcCell->currentRateIndex = 0)\n" + "> - else if (i == rcCell->currentRateIndex == 0)\n" "> - {\n" "> - return 1;\n" "> - }\n" @@ -47,10 +47,10 @@ "> - }\n" "> - }\n" "> + for (i = 0; i < rcCell->operationRateCount; i++) {\n" - "> +\tif (retryRate = rcCell->operationRateSet[i]) {\n" + "> +\tif (retryRate == rcCell->operationRateSet[i]) {\n" "> +\t\tif (i < rcCell->currentRateIndex)\n" "> +\t\t\treturn ((rcCell->currentRateIndex - i)+1)>>1;\n" - "> +\t\telse if (i = rcCell->currentRateIndex && i = 0)\n" + "> +\t\telse if (i == rcCell->currentRateIndex && i == 0)\n" "> +\t\t\treturn 1;\n" "> +\t\telse\n" "> +\t\t\treturn 0;\n" @@ -64,7 +64,7 @@ "i would make the special case i=0 first and let the loop\n" "start with i=1. /* untested code below, assuming rcCell->currentRateIndex>=0 */\n" "\n" - " if ( retryRate = rcCell->operationRateSet[0] && rcCell->currentRateIndex= 0 )\n" + " if ( retryRate == rcCell->operationRateSet[0] && rcCell->currentRateIndex== 0 )\n" "\treturn 1;\n" "\n" " for (i = 1; i < rcCell->operationRateCount; i++) {\n" @@ -81,4 +81,4 @@ "re,\n" wh -4d88983b187cb7ff9dac09a9782cf958da14f4f06339d5c8fa50de9a72cdf385 +a6849a1842a95f545b809749f5c36a8e939aaeec4035679396f8d6c37d05a065
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.