projects
/
openvswitch
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Add dist-hook to ensure that every file gets distributed.
[openvswitch]
/
ofproto
/
ofproto.c
diff --git
a/ofproto/ofproto.c
b/ofproto/ofproto.c
index 1010948357e1c763f23eb3f0a83fd9998f272782..7cca951b40fcb14289b2d421507acbe777cefa2d 100644
(file)
--- a/
ofproto/ofproto.c
+++ b/
ofproto/ofproto.c
@@
-19,6
+19,7
@@
#include "ofproto.h"
#include <errno.h>
#include <inttypes.h>
#include "ofproto.h"
#include <errno.h>
#include <inttypes.h>
+#include <sys/socket.h>
#include <net/if.h>
#include <netinet/in.h>
#include <stdbool.h>
#include <net/if.h>
#include <netinet/in.h>
#include <stdbool.h>
@@
-545,6
+546,10
@@
update_in_band_remotes(struct ofproto *ofproto)
HMAP_FOR_EACH (ofconn, struct ofconn, hmap_node, &ofproto->controllers) {
struct sockaddr_in *sin = &addrs[n_addrs];
HMAP_FOR_EACH (ofconn, struct ofconn, hmap_node, &ofproto->controllers) {
struct sockaddr_in *sin = &addrs[n_addrs];
+ if (ofconn->band == OFPROTO_OUT_OF_BAND) {
+ continue;
+ }
+
sin->sin_addr.s_addr = rconn_get_remote_ip(ofconn->rconn);
if (sin->sin_addr.s_addr) {
sin->sin_port = rconn_get_remote_port(ofconn->rconn);
sin->sin_addr.s_addr = rconn_get_remote_ip(ofconn->rconn);
if (sin->sin_addr.s_addr) {
sin->sin_port = rconn_get_remote_port(ofconn->rconn);
@@
-568,7
+573,9
@@
update_in_band_remotes(struct ofproto *ofproto)
in_band_create(ofproto, ofproto->dpif, ofproto->switch_status,
&ofproto->in_band);
}
in_band_create(ofproto, ofproto->dpif, ofproto->switch_status,
&ofproto->in_band);
}
- in_band_set_remotes(ofproto->in_band, addrs, n_addrs);
+ if (ofproto->in_band) {
+ in_band_set_remotes(ofproto->in_band, addrs, n_addrs);
+ }
ofproto->next_in_band_update = time_msec() + 1000;
} else {
in_band_destroy(ofproto->in_band);
ofproto->next_in_band_update = time_msec() + 1000;
} else {
in_band_destroy(ofproto->in_band);