Refactor {add,remove}_metric functions
Refactor {add,remove}_metric functions

We can refactor the functions to put stopping and saving the values
in its own function, while making the return values consistent.

prasincs/pcp,aeg-aeg/pcpfans,wuliming/pcp,aeg-aeg/pcpfans,andyvand/cygpcpfans,prasincs/pcp,edwardt/pcp,tjanez/pcp,aeg-aeg/pcpfans,andyvand/cygpcpfans,wuliming/pcp,prasincs/pcp,andyvand/cygpcpfans,aeg-aeg/pcpfans,adfernandes/pcp,wuliming/pcp,prasincs/pcp,tjanez/pcp,tjanez/pcp,edwardt/pcp,adfernandes/pcp,adfernandes/pcp,prasincs/pcp,adfernandes/pcp,prasincs/pcp,andyvand/cygpcpfans,edwardt/pcp,mbaldessari/pcp,mbaldessari/pcp,aeg-aeg/pcpfans,mbaldessari/pcp,tjanez/pcp,adfernandes/pcp,wuliming/pcp,wuliming/pcp,andyvand/cygpcpfans,wuliming/pcp,edwardt/pcp,wuliming/pcp,edwardt/pcp,aeg-aeg/pcpfans,edwardt/pcp,adfernandes/pcp,adfernandes/pcp,prasincs/pcp,mbaldessari/pcp,adfernandes/pcp,tjanez/pcp,andyvand/cygpcpfans,tjanez/pcp,prasincs/pcp,wuliming/pcp,edwardt/pcp,aeg-aeg/pcpfans,aeg-aeg/pcpfans,andyvand/cygpcpfans,andyvand/cygpcpfans,mbaldessari/pcp,mbaldessari/pcp,edwardt/pcp,tjanez/pcp,tjanez/pcp