(/home/sate/Testcases/c/cve/wireshark-1.2.0/epan/dfilter/semcheck.c) |
| |
| 290 | | | check_exists(stnode_t *st_arg1) |
| 291 | | | { |
| 292 | | | #ifdef DEBUG_dfilter |
| 293 | | | static guint i = 0; |
| 294 | | | #endif |
| 295 | | | |
| 296 | | | DebugLog((" 4 check_exists() [%u]\n", i++)); |
| 297 | | | switch (stnode_type_id(st_arg1)) { |
| 298 | | | case STTYPE_FIELD: |
| 299 | | | |
| 300 | | | break; |
| 301 | | | case STTYPE_STRING: |
| 302 | | | case STTYPE_UNPARSED: |
| 303 | | | dfilter_fail("\"%s\" is neither a field nor a protocol name.", |
| 304 | | | stnode_data(st_arg1)); |
| 305 | | | THROW(TypeError);
x /home/sate/Testcases/c/cve/wireshark-1.2.0/epan/exceptions.h |
| |
223 | #define THROW(x) \ |
224 | except_throw(XCEPT_GROUP_WIRESHARK, (x), NULL) |
| |
|
| 306 | | | break; |
Unreachable Control Flow
The highlighted code will not execute under any circumstances. |
|
| 307 | | | |
| 308 | | | case STTYPE_RANGE: |
| 309 | | | |
| 310 | | | |
| 311 | | | |
| 312 | | | |
| 313 | | | |
| 314 | | | |
| 315 | | | dfilter_fail("You cannot test whether a range is present."); |
| 316 | | | THROW(TypeError);
x /home/sate/Testcases/c/cve/wireshark-1.2.0/epan/exceptions.h |
| |
223 | #define THROW(x) \ |
224 | except_throw(XCEPT_GROUP_WIRESHARK, (x), NULL) |
| |
|
| 317 | | | break; |
| 318 | | | |
| 319 | | | case STTYPE_FUNCTION: |
| 320 | | | |
| 321 | | | |
| 322 | | | dfilter_fail("You cannot test whether a function is present."); |
| 323 | | | THROW(TypeError);
x /home/sate/Testcases/c/cve/wireshark-1.2.0/epan/exceptions.h |
| |
223 | #define THROW(x) \ |
224 | except_throw(XCEPT_GROUP_WIRESHARK, (x), NULL) |
| |
|
| 324 | | | break; |
| 325 | | | |
| 326 | | | case STTYPE_UNINITIALIZED: |
| 327 | | | case STTYPE_TEST: |
| 328 | | | case STTYPE_INTEGER: |
| 329 | | | case STTYPE_FVALUE: |
| 330 | | | case STTYPE_NUM_TYPES: |
| 331 | | | g_assert_not_reached();
x /usr/include/glib-2.0/glib/gtestutils.h |
| |
73 | #define g_assert_not_reached() do { g_assertion_message (G_LOG_DOMAIN, __FILE__, __LINE__, G_STRFUNC, NULL); } while (0) |
| |
x /usr/include/glib-2.0/glib/gmacros.h |
| |
160 | # define G_STRFUNC ((const char*) (__PRETTY_FUNCTION__)) |
| |
|
| 332 | | | } |
| 333 | | | } |
| |