diff options
author | Andrea Canciani <ranma42@gmail.com> | 2011-07-29 10:46:42 +0200 |
---|---|---|
committer | Andrea Canciani <ranma42@gmail.com> | 2011-07-29 11:54:56 +0200 |
commit | ad3ef3a8fb560a2bd528ccd15469bbe9a1ddcee8 (patch) | |
tree | 1c222d89b496ad5c2a5bcdd51d9420f904916a18 /src/cairo-xcb-shm.c | |
parent | e8e765605c2ae69710affadd3f450aef17932258 (diff) |
Silence Clang static analyzer reports
Clang static analysis triggers some reports in non-buggy code.
Silence them trying to follow better coding practices.
Diffstat (limited to 'src/cairo-xcb-shm.c')
-rw-r--r-- | src/cairo-xcb-shm.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/cairo-xcb-shm.c b/src/cairo-xcb-shm.c index 7695279d..1d630a7c 100644 --- a/src/cairo-xcb-shm.c +++ b/src/cairo-xcb-shm.c @@ -271,7 +271,7 @@ merge_buddies (cairo_xcb_shm_mem_pool_t *pi, cairo_xcb_shm_mem_block_t *block, unsigned int max_bits) { - size_t block_offset = block_offset = block - pi->blocks; + size_t block_offset = block - pi->blocks; unsigned int bits = block->bits; while (bits < max_bits - 1) { @@ -477,6 +477,10 @@ _cairo_xcb_shm_process_pending (cairo_xcb_connection_t *connection, shm_wait_typ * larger sequence number and thus don't have to be checked. */ return; break; + default: + /* silence Clang static analyzer warning */ + ASSERT_NOT_REACHED; + reply = NULL; } free (reply); |