Skip to content

Commit

Permalink
Fix bug: shellquote the inner string (#1168)
Browse files Browse the repository at this point in the history
  • Loading branch information
qiluo-msft committed Jan 17, 2020
1 parent 7b9661b commit b5cde3c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cfgmgr/vlanmgr.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@ bool VlanMgr::removeHostVlanMember(int vlan_id, const string &port_alias)
IP_CMD " link set " << shellquote(port_alias) << " nomaster; "
"elif [ $ret -eq 1 ]; then exit 0; "
"else exit $ret; fi )";
cmds << BASH_CMD " -c " << shellquote(cmds.str());
cmds << BASH_CMD " -c " << shellquote(inner.str());

std::string res;
EXEC_WITH_ERROR_THROW(cmds.str(), res);
Expand Down

0 comments on commit b5cde3c

Please sign in to comment.