Add additional options checking in sedta.

This commit is contained in:
Chris PeBenito 2015-02-07 11:47:07 -05:00
parent a809d3c557
commit 094dbe3906

3
sedta
View File

@ -89,6 +89,9 @@ args = parser.parse_args()
if not args.target and (args.shortest_path or args.all_paths):
parser.error("The target type must be specified to determine a path.")
if args.target and not (args.shortest_path or args.all_paths):
parser.error("An algorithm must be specified to determine a path.")
try:
p = setools.SELinuxPolicy(args.policy)
g = setools.dta.DomainTransitionAnalysis(p)