aboutsummaryrefslogtreecommitdiffstats
path: root/include/osmo-pcap
diff options
context:
space:
mode:
authorHolger Hans Peter Freyther <holger@moiji-mobile.com>2016-11-08 22:53:32 +0100
committerHolger Hans Peter Freyther <holger@moiji-mobile.com>2016-11-09 01:04:04 +0100
commit1448f50db40b06a36783f2d1dd5d8e0ab865aa03 (patch)
tree68a53dd0e9197ca2745702da22652d29a4a182b0 /include/osmo-pcap
parent956c3facf1950e8f84291089972ab8323c75767a (diff)
client: Allow to configure and connect multiple servers
Allow to configure multiple servers and connect. Introduce a new VTY node to allow multiple servers. Add an explicit connect. Do not put the main connection into the same list but assume it exists. Change-Id: I9448ad4a005dd7c7eb1c615d03e57d6cb058ae4d
Diffstat (limited to 'include/osmo-pcap')
-rw-r--r--include/osmo-pcap/common.h3
-rw-r--r--include/osmo-pcap/osmo_pcap_client.h5
2 files changed, 7 insertions, 1 deletions
diff --git a/include/osmo-pcap/common.h b/include/osmo-pcap/common.h
index fff452f..13c76e1 100644
--- a/include/osmo-pcap/common.h
+++ b/include/osmo-pcap/common.h
@@ -1,7 +1,7 @@
/*
* osmo-pcap common
*
- * (C) 2011 by Holger Hans Peter Freyther <zecke@selfish.org>
+ * (C) 2011-2016 by Holger Hans Peter Freyther
* (C) 2011 by On-Waves
* All Rights Reserved
*
@@ -41,6 +41,7 @@ enum {
enum {
CLIENT_NODE = _LAST_OSMOVTY_NODE + 1,
SERVER_NODE,
+ CLIENT_SERVER_NODE,
};
extern const struct log_info log_info;
diff --git a/include/osmo-pcap/osmo_pcap_client.h b/include/osmo-pcap/osmo_pcap_client.h
index fc982f3..5947615 100644
--- a/include/osmo-pcap/osmo_pcap_client.h
+++ b/include/osmo-pcap/osmo_pcap_client.h
@@ -48,6 +48,7 @@ enum {
struct osmo_pcap_client_conn {
struct llist_head entry;
+ const char *name;
char *srv_ip;
int srv_port;
@@ -108,3 +109,7 @@ void osmo_client_send_link(struct osmo_pcap_client_conn *client);
void osmo_client_connect(struct osmo_pcap_client_conn *);
void osmo_client_reconnect(struct osmo_pcap_client_conn *);
+
+struct osmo_pcap_client_conn *osmo_client_find_or_create_conn(struct osmo_pcap_client *, const char *name);
+
+void osmo_client_conn_init(struct osmo_pcap_client_conn *conn, struct osmo_pcap_client *client);