changed handling of spilled ops in write lock #1025

Avoids holding the lock during a network call.