Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!news-1.dfn.de!news.dfn.de!fu-berlin.de!uni-berlin.de!news.dfncis.de!not-for-mail From: =?UTF-8?B?U3ZlbiBLw7ZobGVy?= Newsgroups: comp.lang.java.programmer Subject: Re: exec problem is JDK 1.7.0_21 Date: Sun, 21 Apr 2013 08:31:14 +0300 Lines: 21 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Trace: news.dfncis.de OEqA8oP8kL4oxjUXLV22TgcTc95VUVZ/rIM5iIXNZgKTbkBw7JmCppcsHC Cancel-Lock: sha1:GPEsyLjffPhdYRDJx99dplYVlE0= User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:17.0) Gecko/20130328 Thunderbird/17.0.5 In-Reply-To: Xref: csiph.com comp.lang.java.programmer:23545 Am 21.04.2013 00:56, schrieb Martin Gregorie: > Where do you get the two elements bit? My documentation (Java 6 Javadocs) > says you can pass either a List list of items or one or more > Strings. Neither form requires exactly two elements. The only requirement > is that the first element must be the command name and the rest are the > arguments you're passing to it. If you're not looking at the Javadocs > documentation set for the JDK or JRE you using, then you're working from > incorrect information. Start reading from the top of the page: http://docs.oracle.com/javase/7/docs/api/java/lang/ProcessBuilder.html The first bullet points explains, that on some operating systems (e.g. Windows), a valid command exist of exactly two Strings. The constructor of ProcessBuilder on the other hand states that it does not check whether the provided list of strings is a valid command. Regards, Sven