Skip to content
Snippets Groups Projects
Commit 4623027d authored by Stefano Garzarella's avatar Stefano Garzarella Committed by Jason Wang
Browse files

net: remove unused get_str_sep() function


Since the get_str_sep() function is no longer used in
net/net.c, we can remove it.

Signed-off-by: default avatarStefano Garzarella <sgarzare@redhat.com>
Reviewed-by: default avatarMarkus Armbruster <armbru@redhat.com>
Signed-off-by: default avatarJason Wang <jasowang@redhat.com>
parent add99347
No related branches found
No related tags found
No related merge requests found
......@@ -64,26 +64,6 @@ static QTAILQ_HEAD(, NetClientState) net_clients;
/***********************************************************/
/* network device redirectors */
static int get_str_sep(char *buf, int buf_size, const char **pp, int sep)
{
const char *p, *p1;
int len;
p = *pp;
p1 = strchr(p, sep);
if (!p1)
return -1;
len = p1 - p;
p1++;
if (buf_size > 0) {
if (len > buf_size - 1)
len = buf_size - 1;
memcpy(buf, p, len);
buf[len] = '\0';
}
*pp = p1;
return 0;
}
int parse_host_port(struct sockaddr_in *saddr, const char *str,
Error **errp)
{
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment