o.c.sds.history: Some code improvements.