Med: daemons: Fix expanding ++ and += in multi-update IPC messages.
This is the same problem as for the host attr in
rP3ab3c8e5d83e.
These expansions are only performed in attrd_client_udpate before the
message is sent to all the peer attrd instances. The expansion code
takes place after multi-update IPC messages have been processed and
sent which means that they simply will never take effect in attrd.
The only place where multi-update IPC messages happen right now is in
daemon-to-daemon communications. They are not exposed to users or used
in any other background code. Unfortunately, the fail-count attribute
gets updated by use of ++ expansions and is the one place where
multi-update IPC messages are used.
Thus, the fail-count attribute has simply not been getting incremented
since multi-update IPC messages were introduced.
Fix this by breaking the expansion code out into its own function and
then iterating over all children of the parent message, applying the
expansion if necessary.