Merge -c 1186550 from trunk to branch-0.23 to complete fix for HDFS-2445.

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/branches/branch-0.23@1186551 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Arun Murthy 2011-10-19 22:52:29 +00:00
parent ca752e8dd8
commit 68bea3dc46
2 changed files with 8 additions and 2 deletions

View File

@ -1132,6 +1132,9 @@ Release 0.23.0 - Unreleased
HDFS-2172. Address findbugs and javadoc warnings in HDFS-1073 branch. HDFS-2172. Address findbugs and javadoc warnings in HDFS-1073 branch.
(todd) (todd)
HDFS-2445. Ensure failed tests exit with proper error code. (Jonathan
Eagles via acmurthy)
Release 0.22.0 - Unreleased Release 0.22.0 - Unreleased
INCOMPATIBLE CHANGES INCOMPATIBLE CHANGES

View File

@ -43,11 +43,14 @@ public HdfsTestDriver(ProgramDriver pgd) {
} }
public void run(String argv[]) { public void run(String argv[]) {
int exitCode = -1;
try { try {
pgd.driver(argv); exitCode = pgd.driver(argv);
} catch(Throwable e) { } catch(Throwable e) {
e.printStackTrace(); e.printStackTrace();
} }
System.exit(exitCode);
} }
public static void main(String argv[]){ public static void main(String argv[]){