init checked from googlecode (trunk)