This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

View | Details | Raw Unified | Return to bug 201132
Collapse All | Expand All

(-)a/maven/src/org/netbeans/modules/maven/execute/MavenCommandLineExecutor.java (-1 / +5 lines)
Lines 279-285 Link Here
279
        for (Map.Entry<? extends String,? extends String> entry : config.getProperties().entrySet()) {
279
        for (Map.Entry<? extends String,? extends String> entry : config.getProperties().entrySet()) {
280
            if (!entry.getKey().startsWith(ENV_PREFIX)) {
280
            if (!entry.getKey().startsWith(ENV_PREFIX)) {
281
                //skip envs, these get filled in later.
281
                //skip envs, these get filled in later.
282
                toRet.add("-D" + entry.getKey() + "=" + (Utilities.isWindows() ? entry.getValue().replace(quote, escaped) : entry.getValue().replace(quote, "'")));
282
                String val = entry.getValue();
283
                if (Utilities.isWindows()) {
284
                    val = val.replace("\"", "\"\"");
285
                }
286
                toRet.add("-D" + entry.getKey() + "=" + val);
283
            }
287
            }
284
        }
288
        }
285
289
(-)a/openide.util/src/org/openide/util/Utilities.java (-2 / +3 lines)
Lines 1575-1580 Link Here
1575
        final int slen = s.length();
1575
        final int slen = s.length();
1576
        char c;
1576
        char c;
1577
1577
1578
        boolean win = isWindows();
1578
        for (int i = 0; i < slen; i++) {
1579
        for (int i = 0; i < slen; i++) {
1579
            c = s.charAt(i);
1580
            c = s.charAt(i);
1580
1581
Lines 1585-1598 Link Here
1585
                continue;
1586
                continue;
1586
            }
1587
            }
1587
1588
1588
            if (c == '\\') {
1589
            if (c == '\\' && !win) {
1589
                sb.append('\\').append('\\');
1590
                sb.append('\\').append('\\');
1590
1591
1591
                continue;
1592
                continue;
1592
            }
1593
            }
1593
1594
1594
            if (c == '"') {
1595
            if (c == '"') {
1595
                sb.append('\\').append('"');
1596
                sb.append(win ? '"' : '\\').append('"');
1596
1597
1597
                continue;
1598
                continue;
1598
            }
1599
            }

Return to bug 201132