projects
/
openvswitch
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6d7568d
)
datapath: Avoid possibility of negative 'n_ports' in struct odp_portvec.
author
Ben Pfaff
<blp@nicira.com>
Thu, 13 May 2010 18:04:56 +0000
(11:04 -0700)
committer
Ben Pfaff
<blp@nicira.com>
Thu, 13 May 2010 22:29:47 +0000
(15:29 -0700)
'n_ports' should never be negative so it's better to use an unsigned type.
Suggested-by: Jesse Gross <jesse@nicira.com>
include/openvswitch/datapath-protocol.h
patch
|
blob
|
history
diff --git
a/include/openvswitch/datapath-protocol.h
b/include/openvswitch/datapath-protocol.h
index 1c2dba9b5306750233ae5226765e6e38d2a2d30b..0e8d5c9e0054919d665c1309a65a442b0b5f03f8 100644
(file)
--- a/
include/openvswitch/datapath-protocol.h
+++ b/
include/openvswitch/datapath-protocol.h
@@
-181,7
+181,7
@@
struct odp_port {
struct odp_portvec {
struct odp_port *ports;
-
int
n_ports;
+
__u32
n_ports;
};
struct odp_port_group {