pass rr by reference to set_rdata

In the DNS example, `set_rdata` was erroneously operating on its local copy of the argument only.