minor: input file might not exist.

This commit is contained in:
adrian
2011-04-24 04:03:53 -04:00
committed by Ryszard Wiśniewski
parent 74ecd31a4d
commit 253a95c98d
3 changed files with 51 additions and 0 deletions

View File

@ -18,6 +18,7 @@ package brut.apktool;
import brut.androlib.*;
import brut.androlib.err.CantFindFrameworkResException;
import brut.androlib.err.InFileNotFoundException;
import brut.androlib.err.OutDirExistsException;
import java.io.File;
import java.io.IOException;
@ -122,6 +123,11 @@ public class Main {
"Destination directory (" + outDir.getAbsolutePath() + ") " +
"already exists. Use -f switch if you want to overwrite it.");
System.exit(1);
} catch (InFileNotFoundException ex) {
System.out.println(
"Input file (" + args[i] + ") " +
"was not found or was not readable.");
System.exit(1);
} catch (CantFindFrameworkResException ex) {
System.out.println(
"Can't find framework resources for package of id: " +