Update ofURLFileLoader.cpp

moving the lock outside of the while loop. removing the unneeded locks and unlocks.