Nest: Fix export of tmpattrs through pipes

Pipes copy the original rte with old values, so they require rte to be
exported with stored tmpattrs. Other protocols access stored attributes
using eattr list, so they require rte to be exported with expanded
tmpattrs. This is temporary hack, we plan to remove whoe tmpattr mechanism.

Thanks to Paul Donohue for the bugreport.
This commit is contained in:
Ondrej Zajicek (work) 2021-06-14 20:02:50 +02:00
parent 3ebabab277
commit 1b9bf4e192

View file

@ -618,6 +618,12 @@ export_filter_(struct channel *c, rte *rt0, rte **rt_free, linpool *pool, int si
goto reject; goto reject;
} }
#ifdef CONFIG_PIPE
/* Pipes need rte with stored tmpattrs, remaining protocols need expanded tmpattrs */
if (p->proto == &proto_pipe)
rte_store_tmp_attrs(rt, pool, NULL);
#endif
accept: accept:
if (rt != rt0) if (rt != rt0)
*rt_free = rt; *rt_free = rt;