On Thu, Aug 30, 2018 at 05:08:15PM -0400, 0-day Robot wrote:
> Bleep bloop. Greetings Ben Pfaff, I am a robot and I have tried out your
> patch.
> Thanks for your contribution.
>
> I encountered some error that I wasn't expecting. See the details below.
>
>
> build:
> enum vlog_level level__ = LEVEL; \
> ^
> ./include/openvswitch/vlog.h:218:31: note: in expansion of macro 'VLOG_RL'
> #define VLOG_WARN_RL(RL, ...) VLOG_RL(RL, VLL_WARN, __VA_ARGS__)
> ^
> lib/ofp-msgs.c:461:13: note: in expansion of macro 'VLOG_WARN_RL'
> VLOG_WARN_RL(&rl, "received %s with incorrect length %u (must be
> "
> ^
> ./include/openvswitch/vlog.h:282:14: error: format '%u' expects argument of
> type 'unsigned int', but argument 7 has type 'size_t' [-Werror=format=]
> enum vlog_level level__ = LEVEL; \
> ^
> ./include/openvswitch/vlog.h:218:31: note: in expansion of macro 'VLOG_RL'
> #define VLOG_WARN_RL(RL, ...) VLOG_RL(RL, VLL_WARN, __VA_ARGS__)
> ^
> lib/ofp-msgs.c:461:13: note: in expansion of macro 'VLOG_WARN_RL'
> VLOG_WARN_RL(&rl, "received %s with incorrect length %u (must be
> "
> ^
Good point, I'll fold this in:
diff --git a/lib/ofp-msgs.c b/lib/ofp-msgs.c
index 6b5dfee722a5..ddea4f25ef42 100644
--- a/lib/ofp-msgs.c
+++ b/lib/ofp-msgs.c
@@ -433,11 +433,11 @@ ofpraw_decode_assert(const struct ofp_header *oh)
static enum ofperr
ofpraw_check_length(const struct raw_info *info,
const struct raw_instance *instance,
- size_t len)
+ unsigned int len)
{
static struct vlog_rate_limit rl = VLOG_RATE_LIMIT_INIT(1, 5);
- size_t min_len = instance->hdrs_len + info->min_body;
+ unsigned int min_len = instance->hdrs_len + info->min_body;
switch (info->extra_multiple) {
case 0:
if (len != min_len) {
_______________________________________________
dev mailing list
[email protected]
https://mail.openvswitch.org/mailman/listinfo/ovs-dev