Skip to content

Commit

Permalink
stderr
Browse files Browse the repository at this point in the history
  • Loading branch information
reox committed May 1, 2018
1 parent cd10b0b commit 271ef46
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions androarsc.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@
import sys
from argparse import ArgumentParser
import lxml.etree as etree
import codecs

from androguard.core import androconf
from androguard.core.bytecodes import apk
Expand Down Expand Up @@ -82,15 +81,15 @@ def main(arscobj, outp=None, package=None, typ=None, locale=None):
args = parser.parse_args()

if args.file and args.input:
print("Can not give --input and positional argument! Please use only one of them!")
print("Can not give --input and positional argument! Please use only one of them!", file=sys.stderr)
sys.exit(1)

if args.version:
print("Androaxml version %s" % androconf.ANDROGUARD_VERSION)
sys.exit(0)

if not args.input and not args.file:
print("Give one file to decode!")
print("Give one file to decode!", file=sys.stderr)
sys.exit(1)

if args.input:
Expand All @@ -105,7 +104,7 @@ def main(arscobj, outp=None, package=None, typ=None, locale=None):
elif ret_type == "ARSC":
arscobj = apk.ARSCParser(read(fname))
else:
print("Unknown file type")
print("Unknown file type!", file=sys.stderr)
sys.exit(1)

if args.list_packages:
Expand Down

0 comments on commit 271ef46

Please sign in to comment.