Error fields computation in the RFX-mod2 reversed field pinch