mirror of
https://github.com/openvswitch/ovs
synced 2025-08-30 22:05:19 +00:00
Replace most uses of assert by ovs_assert.
This is a straight search-and-replace, except that I also removed #include <assert.h> from each file where there were no assert calls left. Signed-off-by: Ben Pfaff <blp@nicira.com> Acked-by: Ethan Jackson <ethan@nicira.com>
This commit is contained in:
@@ -27,6 +27,7 @@
|
||||
#include "nx-match.h"
|
||||
#include "ofp-util.h"
|
||||
#include "ofpbuf.h"
|
||||
#include "util.h"
|
||||
#include "vlog.h"
|
||||
|
||||
VLOG_DEFINE_THIS_MODULE(ofp_actions);
|
||||
@@ -794,7 +795,7 @@ ofpacts_from_openflow11(const union ofp_action *in, size_t n_in,
|
||||
static inline const struct STRUCT * \
|
||||
instruction_get_##ENUM(const struct ofp11_instruction *inst)\
|
||||
{ \
|
||||
assert(inst->type == htons(ENUM)); \
|
||||
ovs_assert(inst->type == htons(ENUM)); \
|
||||
return (struct STRUCT *)inst; \
|
||||
} \
|
||||
\
|
||||
@@ -2131,7 +2132,7 @@ ofpact_init(struct ofpact *ofpact, enum ofpact_type type, size_t len)
|
||||
void
|
||||
ofpact_update_len(struct ofpbuf *ofpacts, struct ofpact *ofpact)
|
||||
{
|
||||
assert(ofpact == ofpacts->l2);
|
||||
ovs_assert(ofpact == ofpacts->l2);
|
||||
ofpact->len = (char *) ofpbuf_tail(ofpacts) - (char *) ofpact;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user