[RILMODEM] fix sim mem leak and code cleaning

Signed-off-by: Jarko Poutiainen <Jarko.Poutiainen@oss.tieto.com>