Merge pull request #333 from timiblossom/1.2

Fix spacing and adding more error checking
Priam should not set any replace_address if it is in a restore mode.