Mercurial > hg > truffle
comparison mx/mx_graal.py @ 21118:ae4941602cfa
mx: fix crash when there are no services
author | Gilles Duboscq <gilles.m.duboscq@oracle.com> |
---|---|
date | Mon, 27 Apr 2015 12:04:10 +0200 |
parents | db2de6c2bf95 |
children | 7f78f999512a |
comparison
equal
deleted
inserted
replaced
21117:f6f3f44a1830 | 21118:ae4941602cfa |
---|---|
599 return className[:className.index('<')] | 599 return className[:className.index('<')] |
600 return className | 600 return className |
601 | 601 |
602 def _classifyGraalServices(classNames, graalJars): | 602 def _classifyGraalServices(classNames, graalJars): |
603 classification = {} | 603 classification = {} |
604 if not classNames: | |
605 return classification | |
604 for className in classNames: | 606 for className in classNames: |
605 classification[className] = None | 607 classification[className] = None |
606 javap = mx.java().javap | 608 javap = mx.java().javap |
607 output = subprocess.check_output([javap, '-cp', os.pathsep.join(graalJars)] + classNames, stderr=subprocess.STDOUT) | 609 output = subprocess.check_output([javap, '-cp', os.pathsep.join(graalJars)] + classNames, stderr=subprocess.STDOUT) |
608 lines = output.split(os.linesep) | 610 lines = output.split(os.linesep) |