Author: britter
Date: Thu Jan  9 17:55:46 2014
New Revision: 1556901

URL: http://svn.apache.org/r1556901
Log:
Replace tabs with spaces

Modified:
    
commons/proper/exec/trunk/src/main/java/org/apache/commons/exec/util/StringUtils.java
    
commons/proper/exec/trunk/src/test/java/org/apache/commons/exec/DefaultExecutorTest.java

Modified: 
commons/proper/exec/trunk/src/main/java/org/apache/commons/exec/util/StringUtils.java
URL: 
http://svn.apache.org/viewvc/commons/proper/exec/trunk/src/main/java/org/apache/commons/exec/util/StringUtils.java?rev=1556901&r1=1556900&r2=1556901&view=diff
==============================================================================
--- 
commons/proper/exec/trunk/src/main/java/org/apache/commons/exec/util/StringUtils.java
 (original)
+++ 
commons/proper/exec/trunk/src/main/java/org/apache/commons/exec/util/StringUtils.java
 Thu Jan  9 17:55:46 2014
@@ -92,10 +92,10 @@ public class StringUtils {
                         for (++cIdx; cIdx < argStr.length(); ++cIdx) {
                             ch = argStr.charAt(cIdx);
                             if (ch == '_' || ch == '.' || ch == '-' || ch == 
'+' || Character.isLetterOrDigit(ch)) {
-                                                               
nameBuf.append(ch);
-                                                       } else {
-                                                               break;
-                                                       }
+                                nameBuf.append(ch);
+                            } else {
+                                break;
+                            }
                         }
 
                         if (nameBuf.length() >= 0) {
@@ -233,8 +233,8 @@ public class StringUtils {
                 throw new IllegalArgumentException(
                         "Can't handle single and double quotes in same 
argument");
             }
-                       return 
buf.append(SINGLE_QUOTE).append(cleanedArgument).append(
-                               SINGLE_QUOTE).toString();
+            return buf.append(SINGLE_QUOTE).append(cleanedArgument).append(
+                    SINGLE_QUOTE).toString();
         } else if (cleanedArgument.indexOf(SINGLE_QUOTE) > -1
                 || cleanedArgument.indexOf(" ") > -1) {
             return buf.append(DOUBLE_QUOTE).append(cleanedArgument).append(

Modified: 
commons/proper/exec/trunk/src/test/java/org/apache/commons/exec/DefaultExecutorTest.java
URL: 
http://svn.apache.org/viewvc/commons/proper/exec/trunk/src/test/java/org/apache/commons/exec/DefaultExecutorTest.java?rev=1556901&r1=1556900&r2=1556901&view=diff
==============================================================================
--- 
commons/proper/exec/trunk/src/test/java/org/apache/commons/exec/DefaultExecutorTest.java
 (original)
+++ 
commons/proper/exec/trunk/src/test/java/org/apache/commons/exec/DefaultExecutorTest.java
 Thu Jan  9 17:55:46 2014
@@ -864,8 +864,8 @@ public class DefaultExecutorTest {
         assertFalse(exec.isFailure(exitValue));
 
         if (OS.isFamilyUnix()) {
-               // the parameters fall literally apart under Windows - need to 
disable the check for Win32
-               assertEquals(expected, result);
+            // the parameters fall literally apart under Windows - need to 
disable the check for Win32
+            assertEquals(expected, result);
         }
     }
 
@@ -943,32 +943,32 @@ public class DefaultExecutorTest {
     @Test
     public void testExec41WithoutStreams() throws Exception {
 
-               final CommandLine cmdLine = new CommandLine(pingScript);
-               cmdLine.addArgument("10"); // sleep 10 secs
-               final DefaultExecutor executor = new DefaultExecutor();
-               final ExecuteWatchdog watchdog = new ExecuteWatchdog(2*1000); 
// allow process no more than 2 secs
+        final CommandLine cmdLine = new CommandLine(pingScript);
+        cmdLine.addArgument("10"); // sleep 10 secs
+        final DefaultExecutor executor = new DefaultExecutor();
+        final ExecuteWatchdog watchdog = new ExecuteWatchdog(2*1000); // allow 
process no more than 2 secs
 
         // create a custom "PumpStreamHandler" doing no pumping at all
         final PumpStreamHandler pumpStreamHandler = new 
PumpStreamHandler(null, null, null);
 
-               executor.setWatchdog(watchdog);
+        executor.setWatchdog(watchdog);
         executor.setStreamHandler(pumpStreamHandler);
 
-               final long startTime = System.currentTimeMillis();
+        final long startTime = System.currentTimeMillis();
 
-               try {
-                       executor.execute(cmdLine);
-               } catch (final ExecuteException e) {
-                       System.out.println(e);
-               }
+        try {
+            executor.execute(cmdLine);
+        } catch (final ExecuteException e) {
+            System.out.println(e);
+        }
 
         final long duration = System.currentTimeMillis() - startTime;
 
-               System.out.println("Process completed in " + duration +" 
millis; below is its output");
+        System.out.println("Process completed in " + duration +" millis; below 
is its output");
 
-               if (watchdog.killedProcess()) {
-                       System.out.println("Process timed out and was killed.");
-               }
+        if (watchdog.killedProcess()) {
+            System.out.println("Process timed out and was killed.");
+        }
 
         assertTrue("The process was killed by the watchdog", 
watchdog.killedProcess());
         assertTrue("Skipping the Thread.join() did not work, 
duration="+duration, duration < 9000);


Reply via email to