From: <pj...@us...> - 2009-05-16 02:02:23
|
Revision: 6352 http://jython.svn.sourceforge.net/jython/?rev=6352&view=rev Author: pjenvey Date: 2009-05-16 01:58:51 +0000 (Sat, 16 May 2009) Log Message: ----------- refactor Modified Paths: -------------- trunk/jython/src/org/python/util/jython.java Modified: trunk/jython/src/org/python/util/jython.java =================================================================== --- trunk/jython/src/org/python/util/jython.java 2009-05-16 01:14:07 UTC (rev 6351) +++ trunk/jython/src/org/python/util/jython.java 2009-05-16 01:58:51 UTC (rev 6352) @@ -317,18 +317,19 @@ * unexpected behavior with the std file streams. */ private static InteractiveConsole newInterpreter(boolean interactiveStdin) { - if (interactiveStdin) { - String interpClass = PySystemState.registry.getProperty("python.console", ""); - if (interpClass.length() > 0) { - try { - return (InteractiveConsole)Class.forName(interpClass).newInstance(); - } catch (Throwable t) { - // fall through - } + if (!interactiveStdin) { + return new InteractiveConsole(); + } + + String interpClass = PySystemState.registry.getProperty("python.console", ""); + if (interpClass.length() == 0) { + try { + return (InteractiveConsole)Class.forName(interpClass).newInstance(); + } catch (Throwable t) { + // fall through } - return new JLineConsole(); } - return new InteractiveConsole(); + return new JLineConsole(); } /** This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |