copy from a pvUnion to a pvUnion does a shallow instead of deep copy.
This is fixed in
https://github.com/mrkraimer/pvDataJava
A pull request should be created sometime soon and this will also be fixed.
Note that this problem does not exist in pvDataCPP.