diff --git a/src/util/virnetdevopenvswitch.c b/src/util/virnetdevopenvswitch.c index f9b3369b2a..bd840bd3b7 100644 --- a/src/util/virnetdevopenvswitch.c +++ b/src/util/virnetdevopenvswitch.c @@ -575,6 +575,7 @@ virNetDevOpenvswitchGetVhostuserIfname(const char *path, return 0; } + virStringTrimOptionalNewline(*ifname); if (virNetDevOpenvswitchMaybeUnescapeReply(*ifname) < 0) { VIR_FREE(*ifname); return -1;