receive-pack.c: add execute_commands_atomic function