diff options
author | Michael Adam <obnox@samba.org> | 2016-01-25 16:22:57 +0100 |
---|---|---|
committer | Michael Adam <obnox@samba.org> | 2016-01-26 07:33:16 +0100 |
commit | 9fcf87419f3f68429bb365ffb605be3eacc97e15 (patch) | |
tree | 80f6b17e23adac016bfb820c97337c9fba8ac13e /source4/lib | |
parent | 8284b34f95639ad7c2e3a97b514529201c20e2ed (diff) | |
download | samba-9fcf87419f3f68429bb365ffb605be3eacc97e15.tar.gz |
s4:lib:socket: skip extra data in interpret_interface()
This is currently smbd-specific.
No need to duplicate the extended parsing
while these functions have not been merged yet.
Signed-off-by: Michael Adam <obnox@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Diffstat (limited to 'source4/lib')
-rw-r--r-- | source4/lib/socket/interface.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/source4/lib/socket/interface.c b/source4/lib/socket/interface.c index 504a7277e32..9b0d00e01b7 100644 --- a/source4/lib/socket/interface.c +++ b/source4/lib/socket/interface.c @@ -178,6 +178,15 @@ static void interpret_interface(TALLOC_CTX *mem_ctx, return; } + p = strchr_m(token, ';'); + if (p != NULL) { + /* + * skip smbd-specific extra data: + * link speed, capabilities, and interface index + */ + *p = 0; + } + /* maybe it is a DNS name */ p = strchr_m(token,'/'); if (p == NULL) { |