summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/command_match.c1
-rw-r--r--lib/jhash.c11
-rw-r--r--lib/workqueue.c18
3 files changed, 21 insertions, 9 deletions
diff --git a/lib/command_match.c b/lib/command_match.c
index 75d8fdc3d3..5a57bb9191 100644
--- a/lib/command_match.c
+++ b/lib/command_match.c
@@ -403,6 +403,7 @@ command_complete (struct graph *graph,
trace_matcher ("trivial_match\n");
if (exact_match_exists && !last_token)
break;
+ /* fallthru */
case exact_match:
trace_matcher ("exact_match\n");
if (last_token)
diff --git a/lib/jhash.c b/lib/jhash.c
index 6154c34630..33589b64e2 100644
--- a/lib/jhash.c
+++ b/lib/jhash.c
@@ -74,24 +74,34 @@ jhash (const void *key, u_int32_t length, u_int32_t initval)
{
case 11:
c += ((u_int32_t) k[10] << 24);
+ /* fallthru */
case 10:
c += ((u_int32_t) k[9] << 16);
+ /* fallthru */
case 9:
c += ((u_int32_t) k[8] << 8);
+ /* fallthru */
case 8:
b += ((u_int32_t) k[7] << 24);
+ /* fallthru */
case 7:
b += ((u_int32_t) k[6] << 16);
+ /* fallthru */
case 6:
b += ((u_int32_t) k[5] << 8);
+ /* fallthru */
case 5:
b += k[4];
+ /* fallthru */
case 4:
a += ((u_int32_t) k[3] << 24);
+ /* fallthru */
case 3:
a += ((u_int32_t) k[2] << 16);
+ /* fallthru */
case 2:
a += ((u_int32_t) k[1] << 8);
+ /* fallthru */
case 1:
a += k[0];
};
@@ -129,6 +139,7 @@ jhash2 (const u_int32_t *k, u_int32_t length, u_int32_t initval)
{
case 2:
b += k[1];
+ /* fallthru */
case 1:
a += k[0];
};
diff --git a/lib/workqueue.c b/lib/workqueue.c
index 3600df2f23..60119f1f41 100644
--- a/lib/workqueue.c
+++ b/lib/workqueue.c
@@ -331,14 +331,14 @@ work_queue_run (struct thread *thread)
{
item->ran--;
work_queue_item_requeue (wq, node);
- /* If a single node is being used with a meta-queue (e.g., zebra),
- * update the next node as we don't want to exit the thread and
- * reschedule it after every node. By definition, WQ_REQUEUE is
- * meant to continue the processing; the yield logic will kick in
- * to terminate the thread when time has exceeded.
- */
- if (nnode == NULL)
- nnode = node;
+ /* If a single node is being used with a meta-queue (e.g., zebra),
+ * update the next node as we don't want to exit the thread and
+ * reschedule it after every node. By definition, WQ_REQUEUE is
+ * meant to continue the processing; the yield logic will kick in
+ * to terminate the thread when time has exceeded.
+ */
+ if (nnode == NULL)
+ nnode = node;
break;
}
case WQ_RETRY_NOW:
@@ -348,7 +348,7 @@ work_queue_run (struct thread *thread)
if (wq->spec.errorfunc)
wq->spec.errorfunc (wq, item);
}
- /* fall through here is deliberate */
+ /* fallthru */
case WQ_SUCCESS:
default:
{