csharpsquid:S2583 false positive

SonarClould seems providing a false positive of that rule on this type of code:

var retries = 0;
var ok = false;
do
{
	try
	{
		// Try do something...
		ok = true;
	}
	catch
	{
		retries++;
	}
}
while (!ok && retries < 5);

Hi @Christian_Salvanesch

We can confirm that it is indeed a false positive. This is a known issue which has the same root cause as the one described here: https://github.com/SonarSource/sonar-dotnet/issues/2600.

Thanks for your feedback!