Ticket #250: [patch]delete_tmpfile_when_not_null.diff
File [patch]delete_tmpfile_when_not_null.diff, 750 bytes (added by , 17 years ago) |
---|
-
src/org/openstreetmap/josm/actions/SaveActionBase.java
125 125 copy(file, tmpFile); 126 126 } 127 127 OsmWriter.output(new FileOutputStream(file), new OsmWriter.All(layer.data, false)); 128 if ( !Main.pref.getBoolean("save.keepbackup"))128 if (tmpFile != null && !Main.pref.getBoolean("save.keepbackup")) 129 129 tmpFile.delete(); 130 130 } else if (ExtensionFileFilter.filters[ExtensionFileFilter.CSV].acceptName(file.getPath())) { 131 131 JOptionPane.showMessageDialog(Main.parent, tr("CSV output not supported yet."));