Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion src/Xamarin.Android.Tools.AndroidSdk/JdkInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -350,7 +350,14 @@ static IEnumerable<string> GetLibexecJdkPaths (Action<TraceLevel, string> logger
return;
xml.Append (e.Data);
}, includeStderr: false);
var plist = XElement.Parse (xml.ToString ());

XElement plist;
try {
plist = XElement.Parse (xml.ToString ());
} catch (XmlException e) {
logger (TraceLevel.Warning, string.Format (Resources.InvalidXmlLibExecJdk_path_args_message, jhp.FileName, jhp.Arguments, e.Message));
yield break;
}
foreach (var info in plist.Elements ("array").Elements ("dict")) {
var JVMHomePath = (XNode) info.Elements ("key").FirstOrDefault (e => e.Value == "JVMHomePath");
if (JVMHomePath == null)
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -130,4 +130,7 @@
{0} - The path of the file being read.
{1} - The exception message of the associated exception.</comment>
</data>
<data name="InvalidXmlLibExecJdk_path_args_message" xml:space="preserve">
<value>An exception occurred while reading the output of '{0} {1}'. Exception: {2}</value>
</data>
</root>
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,11 @@
{0} - The path of the file being read.
{1} - The exception message of the associated exception.</note>
</trans-unit>
<trans-unit id="InvalidXmlLibExecJdk_path_args_message">
<source>An exception occurred while reading the output of '{0} {1}'. Exception: {2}</source>
<target state="new">An exception occurred while reading the output of '{0} {1}'. Exception: {2}</target>
<note />
</trans-unit>
</body>
</file>
</xliff>
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,11 @@
{0} - The path of the file being read.
{1} - The exception message of the associated exception.</note>
</trans-unit>
<trans-unit id="InvalidXmlLibExecJdk_path_args_message">
<source>An exception occurred while reading the output of '{0} {1}'. Exception: {2}</source>
<target state="new">An exception occurred while reading the output of '{0} {1}'. Exception: {2}</target>
<note />
</trans-unit>
</body>
</file>
</xliff>
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,11 @@
{0} - The path of the file being read.
{1} - The exception message of the associated exception.</note>
</trans-unit>
<trans-unit id="InvalidXmlLibExecJdk_path_args_message">
<source>An exception occurred while reading the output of '{0} {1}'. Exception: {2}</source>
<target state="new">An exception occurred while reading the output of '{0} {1}'. Exception: {2}</target>
<note />
</trans-unit>
</body>
</file>
</xliff>
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,11 @@
{0} - The path of the file being read.
{1} - The exception message of the associated exception.</note>
</trans-unit>
<trans-unit id="InvalidXmlLibExecJdk_path_args_message">
<source>An exception occurred while reading the output of '{0} {1}'. Exception: {2}</source>
<target state="new">An exception occurred while reading the output of '{0} {1}'. Exception: {2}</target>
<note />
</trans-unit>
</body>
</file>
</xliff>
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,11 @@
{0} - The path of the file being read.
{1} - The exception message of the associated exception.</note>
</trans-unit>
<trans-unit id="InvalidXmlLibExecJdk_path_args_message">
<source>An exception occurred while reading the output of '{0} {1}'. Exception: {2}</source>
<target state="new">An exception occurred while reading the output of '{0} {1}'. Exception: {2}</target>
<note />
</trans-unit>
</body>
</file>
</xliff>
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,11 @@
{0} - The path of the file being read.
{1} - The exception message of the associated exception.</note>
</trans-unit>
<trans-unit id="InvalidXmlLibExecJdk_path_args_message">
<source>An exception occurred while reading the output of '{0} {1}'. Exception: {2}</source>
<target state="new">An exception occurred while reading the output of '{0} {1}'. Exception: {2}</target>
<note />
</trans-unit>
</body>
</file>
</xliff>
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,11 @@
{0} - The path of the file being read.
{1} - The exception message of the associated exception.</note>
</trans-unit>
<trans-unit id="InvalidXmlLibExecJdk_path_args_message">
<source>An exception occurred while reading the output of '{0} {1}'. Exception: {2}</source>
<target state="new">An exception occurred while reading the output of '{0} {1}'. Exception: {2}</target>
<note />
</trans-unit>
</body>
</file>
</xliff>
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,11 @@
{0} - The path of the file being read.
{1} - The exception message of the associated exception.</note>
</trans-unit>
<trans-unit id="InvalidXmlLibExecJdk_path_args_message">
<source>An exception occurred while reading the output of '{0} {1}'. Exception: {2}</source>
<target state="new">An exception occurred while reading the output of '{0} {1}'. Exception: {2}</target>
<note />
</trans-unit>
</body>
</file>
</xliff>
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,11 @@
{0} - The path of the file being read.
{1} - The exception message of the associated exception.</note>
</trans-unit>
<trans-unit id="InvalidXmlLibExecJdk_path_args_message">
<source>An exception occurred while reading the output of '{0} {1}'. Exception: {2}</source>
<target state="new">An exception occurred while reading the output of '{0} {1}'. Exception: {2}</target>
<note />
</trans-unit>
</body>
</file>
</xliff>
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,11 @@
{0} - The path of the file being read.
{1} - The exception message of the associated exception.</note>
</trans-unit>
<trans-unit id="InvalidXmlLibExecJdk_path_args_message">
<source>An exception occurred while reading the output of '{0} {1}'. Exception: {2}</source>
<target state="new">An exception occurred while reading the output of '{0} {1}'. Exception: {2}</target>
<note />
</trans-unit>
</body>
</file>
</xliff>
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,11 @@
{0} - The path of the file being read.
{1} - The exception message of the associated exception.</note>
</trans-unit>
<trans-unit id="InvalidXmlLibExecJdk_path_args_message">
<source>An exception occurred while reading the output of '{0} {1}'. Exception: {2}</source>
<target state="new">An exception occurred while reading the output of '{0} {1}'. Exception: {2}</target>
<note />
</trans-unit>
</body>
</file>
</xliff>
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,11 @@
{0} - The path of the file being read.
{1} - The exception message of the associated exception.</note>
</trans-unit>
<trans-unit id="InvalidXmlLibExecJdk_path_args_message">
<source>An exception occurred while reading the output of '{0} {1}'. Exception: {2}</source>
<target state="new">An exception occurred while reading the output of '{0} {1}'. Exception: {2}</target>
<note />
</trans-unit>
</body>
</file>
</xliff>
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,11 @@
{0} - The path of the file being read.
{1} - The exception message of the associated exception.</note>
</trans-unit>
<trans-unit id="InvalidXmlLibExecJdk_path_args_message">
<source>An exception occurred while reading the output of '{0} {1}'. Exception: {2}</source>
<target state="new">An exception occurred while reading the output of '{0} {1}'. Exception: {2}</target>
<note />
</trans-unit>
</body>
</file>
</xliff>