Added the modified Ricart-Agrawala code