try {
uploadloop:while(true) {
try {
getProgressMonitor().subTask(trn("Uploading {0} object...", "Uploading {0} objects...", toUpload.getSize(), toUpload.getSize()));
synchronized(this) {
writer = new OsmServerWriter();
}
writer.uploadOsm(strategy, toUpload.getPrimitives(), changeset, getProgressMonitor().createSubTaskMonitor(1, false));
// if we get here we've successfully uploaded the data. Exit the loop.
//