loci: add default cases to wire buf accessors
We don't expect these to change again.
diff --git a/c_gen/templates/of_wire_buf.h b/c_gen/templates/of_wire_buf.h
index 0922a69..3d38f53 100644
--- a/c_gen/templates/of_wire_buf.h
+++ b/c_gen/templates/of_wire_buf.h
@@ -469,14 +469,10 @@
of_wire_buffer_u16_get(wbuf, offset, &v16);
*value = v16;
break;
- case OF_VERSION_1_1:
- case OF_VERSION_1_2:
- case OF_VERSION_1_3:
+ default:
of_wire_buffer_u32_get(wbuf, offset, &v32);
*value = v32;
break;
- default:
- LOCI_ASSERT(0);
}
}
@@ -498,13 +494,9 @@
case OF_VERSION_1_0:
of_wire_buffer_u16_set(wbuf, offset, (uint16_t)value);
break;
- case OF_VERSION_1_1:
- case OF_VERSION_1_2:
- case OF_VERSION_1_3:
+ default:
of_wire_buffer_u32_set(wbuf, offset, (uint32_t)value);
break;
- default:
- LOCI_ASSERT(0);
}
}
@@ -527,14 +519,10 @@
of_wire_buffer_u16_get(wbuf, offset, &v16);
*value = v16;
break;
- case OF_VERSION_1_1:
- case OF_VERSION_1_2:
- case OF_VERSION_1_3:
+ default:
of_wire_buffer_u8_get(wbuf, offset, &v8);
*value = v8;
break;
- default:
- LOCI_ASSERT(0);
}
}
@@ -553,13 +541,9 @@
case OF_VERSION_1_0:
of_wire_buffer_u16_set(wbuf, offset, (uint16_t)value);
break;
- case OF_VERSION_1_1:
- case OF_VERSION_1_2:
- case OF_VERSION_1_3:
+ default:
of_wire_buffer_u8_set(wbuf, offset, (uint8_t)value);
break;
- default:
- LOCI_ASSERT(0);
}
}
@@ -583,13 +567,10 @@
of_wire_buffer_u32_get(wbuf, offset, &v32);
*value = v32;
break;
- case OF_VERSION_1_2:
- case OF_VERSION_1_3:
+ default:
of_wire_buffer_u64_get(wbuf, offset, &v64);
*value = v64;
break;
- default:
- LOCI_ASSERT(0);
}
}
@@ -609,12 +590,9 @@
case OF_VERSION_1_1:
of_wire_buffer_u32_set(wbuf, offset, (uint32_t)value);
break;
- case OF_VERSION_1_2:
- case OF_VERSION_1_3:
+ default:
of_wire_buffer_u64_set(wbuf, offset, (uint64_t)value);
break;
- default:
- LOCI_ASSERT(0);
}
}