main-coverity-RootStorageSvc
address two minor coverity defects: use std::move where possible, and branches of 'if' are identical. Annotated a third coverity defect: integer overflow for the idx1 variable. THis would need a unit test on the text manipulation before fixing, I think.