[PATCH 0/2] route: fix rtnl_tc_clone()

Thomas Haller thaller at redhat.com
Mon Nov 24 08:19:52 PST 2014


I think that most oo_clone() implementations have the
problem that they might return early (with NLE_NOMEM).

On failure of oo_clone(), we free 'new'. Hence we must make
sure that 'new' does not own parts of 'src'.

Thomas Haller (2):
  route: set missing TCA_ATTR_XSTATS changes flags in
    rtnl_tc_msg_parse()
  route: make rtnl_tc_clone() more robust agaoins NLE_NOMEM

 lib/route/tc.c | 11 ++++++++++-
 1 file changed, 10 insertions(+), 1 deletion(-)

-- 
1.9.3




More information about the libnl mailing list