Changeset 12601 in josm


Ignore:
Timestamp:
2017-08-14T13:38:42+02:00 (2 years ago)
Author:
Don-vip
Message:

see #15149 - less verbose logs when starting JOSM in debug

Location:
trunk/src/org/openstreetmap/josm
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/data/Preferences.java

    r12537 r12601  
    671671
    672672    private static void setCorrectPermissions(File file) {
    673         if (!file.setReadable(false, false) && Main.isDebugEnabled()) {
    674             Main.debug(tr("Unable to set file non-readable {0}", file.getAbsolutePath()));
    675         }
    676         if (!file.setWritable(false, false) && Main.isDebugEnabled()) {
    677             Main.debug(tr("Unable to set file non-writable {0}", file.getAbsolutePath()));
    678         }
    679         if (!file.setExecutable(false, false) && Main.isDebugEnabled()) {
    680             Main.debug(tr("Unable to set file non-executable {0}", file.getAbsolutePath()));
    681         }
    682         if (!file.setReadable(true, true) && Main.isDebugEnabled()) {
    683             Main.debug(tr("Unable to set file readable {0}", file.getAbsolutePath()));
    684         }
    685         if (!file.setWritable(true, true) && Main.isDebugEnabled()) {
    686             Main.debug(tr("Unable to set file writable {0}", file.getAbsolutePath()));
     673        if (!file.setReadable(false, false) && Main.isTraceEnabled()) {
     674            Main.trace(tr("Unable to set file non-readable {0}", file.getAbsolutePath()));
     675        }
     676        if (!file.setWritable(false, false) && Main.isTraceEnabled()) {
     677            Main.trace(tr("Unable to set file non-writable {0}", file.getAbsolutePath()));
     678        }
     679        if (!file.setExecutable(false, false) && Main.isTraceEnabled()) {
     680            Main.trace(tr("Unable to set file non-executable {0}", file.getAbsolutePath()));
     681        }
     682        if (!file.setReadable(true, true) && Main.isTraceEnabled()) {
     683            Main.trace(tr("Unable to set file readable {0}", file.getAbsolutePath()));
     684        }
     685        if (!file.setWritable(true, true) && Main.isTraceEnabled()) {
     686            Main.trace(tr("Unable to set file writable {0}", file.getAbsolutePath()));
    687687        }
    688688    }
  • trunk/src/org/openstreetmap/josm/tools/Utils.java

    r12594 r12601  
    12781278        if (value != null) {
    12791279            String old = System.setProperty(key, value);
    1280             if (Main.isDebugEnabled()) {
     1280            if (Main.isDebugEnabled() && !value.equals(old)) {
    12811281                if (!key.toLowerCase(Locale.ENGLISH).contains("password")) {
    12821282                    Main.debug("System property '" + key + "' set to '" + value + "'. Old value was '" + old + '\'');
Note: See TracChangeset for help on using the changeset viewer.