Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[eclipse-dev] Command line processing bug fixed


In the past Eclipse has been rather, uhhh, variable with respect to its handling of command line arguments.  The theory was that the various layers of Eclipse (e.g., eclipse.exe, boot, runtime,...) itself would strip off the command line arguments it wanted and leave the rest for the next layer until ultimately the application would get the left overs.  Unfortunately, the various layers were not always consistent in what they stripped and what they passed through.  From time to time bugs would be reported and workarounds proposed but for whatever reason, the problem was never actually fixed.

No longer!  As of today's build, Eclipse now correctly strips all framework and runtime arguments as they flow up to the Eclipse application.  As a result, the application will see only those arguments which were not destine for some part of Eclipse itself.  It is possible for this correction to impact applications which assumed that they would be passed the full set of command line arguments or indeed that these args are supplied in any particular order.  Application authors should review their command line processing to ensure that their assumptions are reasonable.

Note that you can continue to use
        org.eclipse.core.runtime.Platform.getCommandLineArgs()
to get the full set of arguments on the orginal command line and the new method
        org.eclipse.core.runtime.Platform.getAppicationArgs()
gives the subset of the command line passed through to the application.

Jeff

Back to the top