flow: fix parsing known switch statements
The problem is that this code was ignoring the ->case_statement pointer
which is the first statement after a case statement. It can be a block
as in the following example code:
switch (2) {
case 2: {
frob(); frob(); frob();
break;
}
...
We need to parse the first statement (which can be block statement with
other statements inside) and then check for if the __path_is_null().
This code is still not perfect. If the default statement comes first it
assumes that it is a match. Also Smatch needs to handle impossible paths
better for switch statements. I don't think that's handled correctly...
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>