Community
Participate
Working Groups
Build ID: M20071023-1652 Steps To Reproduce: 1. create a launch configuration for a simple Java app that has a main(String[] args) method 2. in the launch editor, pass an argument "*.java" 3. when debugging into main, the argument is automatically expanded into all files that match the pattern More information: 1. why is Eclipse JDT assuming every wildcard-parameter are files? 2. why is it acting super-intelligent even when using "quotes" to circumvent this A.I.? 3. why is it acting differently than Sun's JRE that correctly passes the wildcards when invoked from the commandline (only with the argument in quotes)? Please ensure that quoted arguments are not expanded in any way. I tried with Java5/Java6, same in Eclipse (=not working) and on the command line (=working)
This appears to be a WinXP behavior. I don't think we have control over it.
*** Bug 235406 has been marked as a duplicate of this bug. ***
is it OS specific of VM specific? I'm wondering if exec() is just implemented differently. I assume that when we launch Eclipse we are actully just exec()'ing something (java.exe? eclipse.exe?)
Launching something usually comes down to using java.lang.Runtime.exec(...). For Java apps, we exec java.exe. For Eclipse, I don't recall if it is eclipse.exe or java.exe... However, it appears that on WinXP, when "*" is passed as a command line parameter, it is expanded. Same thing happens from the command line. The bug is that from the command line, a quoted asterix ("*") just passes * whereas from Eclipse, a quoted asterix does end up as a literal.
(In reply to comment #4) > a quoted asterix does end up as a literal. does *not* end up as a literal.
Looks like a bug in our ArgumentsParser. If I intercept the command line and add the quotes explicitly, it works. Targeting for 3.4.1, as this is delicate code with OS specifics.
Moving to 3.5 unless this is blocking anyone.
and so it goes... not planned for 3.5.
Still experiencing this bug, another four years later, in Windows 7.
The bug is still present in Eclipse Luna (Release (4.4.0)) and continues to confuse people.
This is apparently a bug (or an undocumented feature?) in "java.exe" of all Java versions up to and including (at least) Java 8: With SYSINTERNALS PROCEXP, you see "*" in the command line of the running java.exe process, but "args[]" contains the expanded file names. I am desperately searching for a workaround that suppresses this nasty command line expansion - any help appreciated!
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet. If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant. -- The automated Eclipse Genie.