On De-serialization, the transient variable lock get to their Default value ie null

On De-serialization, the transient variable lock get to their Default value ie null. 
- make sure that the lock is not null; if it is. initialise it