Updates to the RPC listener code

Fixed the openFile method, made several minor updates.

Change-Id: I85b0c4b112335890f9b3b5bd51035d7282d12c7b
Merge branch 'update-rpc-class'

Change-Id: I4f6410360c7e3d78e2e7257054f0756dce3c74ed